package ai.decompile.analysis.model.entity;

import jakarta.persistence.*;
import java.util.UUID;
import lombok.*;

@Entity
@Table(name = "static_segment")
@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class StaticSegment {
  @Id
  @GeneratedValue(strategy = GenerationType.UUID)
  private UUID id;

  @ManyToOne(fetch = FetchType.LAZY)
  @JoinColumn(name = "analysis_id", nullable = false)
  private StaticAnalysis analysis;

  @Column(nullable = false, length = 100)
  private String name;

  @Column(name = "start_address", nullable = false, length = 20)
  private String startAddress;

  @Column(name = "end_address", nullable = false, length = 20)
  private String endAddress;
}
