當前位置: 首頁>>代碼示例>>Java>>正文


Java AccessType.PROPERTY屬性代碼示例

本文整理匯總了Java中javax.persistence.AccessType.PROPERTY屬性的典型用法代碼示例。如果您正苦於以下問題:Java AccessType.PROPERTY屬性的具體用法?Java AccessType.PROPERTY怎麽用?Java AccessType.PROPERTY使用的例子?那麽, 這裏精選的屬性代碼示例或許可以為您提供幫助。您也可以進一步了解該屬性所在javax.persistence.AccessType的用法示例。


在下文中一共展示了AccessType.PROPERTY屬性的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: determineAccessTypeByIdPlacement

private static AccessType determineAccessTypeByIdPlacement(List<AnnotationInstance> idAnnotations) {
	AccessType accessType = null;
	for ( AnnotationInstance annotation : idAnnotations ) {
		AccessType tmpAccessType;
		if ( annotation.target() instanceof FieldInfo ) {
			tmpAccessType = AccessType.FIELD;
		}
		else if ( annotation.target() instanceof MethodInfo ) {
			tmpAccessType = AccessType.PROPERTY;
		}
		else {
			throw new AnnotationException( "Invalid placement of @Id annotation" );
		}

		if ( accessType == null ) {
			accessType = tmpAccessType;
		}
		else {
			if ( !accessType.equals( tmpAccessType ) ) {
				throw new AnnotationException( "Inconsistent placement of @Id annotation within hierarchy " );
			}
		}
	}
	return accessType;
}
 
開發者ID:lamsfoundation,項目名稱:lams,代碼行數:25,代碼來源:EntityHierarchyBuilder.java

示例2: getId

@Override
@Id
@Size(min = 16, max = 255)
@Access(value = AccessType.PROPERTY)
@Column(name = "token_data", nullable = false, length = 255)
public String getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:EmailToken.java

示例3: getId

@Override
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Access(value = AccessType.PROPERTY)
@Column(name = "harvest_permit_area_partner_id", nullable = false)
public Long getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:HarvestPermitAreaPartner.java

示例4: getId

@Override
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Access(value = AccessType.PROPERTY)
@Column(name = "harvest_permit_area_rhy_id", nullable = false)
public Long getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:HarvestPermitAreaRhy.java

示例5: getId

@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Column(name = "game_observation_id", nullable = false)
@Access(value = AccessType.PROPERTY)
@Override
public Long getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:Observation.java

示例6: getId

@Override
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Access(value = AccessType.PROPERTY)
@Column(nullable = false)
public Long getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:DateTestEntity.java

示例7: getId

@Override
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Access(value = AccessType.PROPERTY)
@Column(name = "harvest_permit_area_id", nullable = false)
public Long getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:HarvestPermitArea.java

示例8: getId

@Override
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Access(value = AccessType.PROPERTY)
@Column(name = "hunting_club_member_invitation_id", nullable = false)
public Long getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:HuntingClubMemberInvitation.java

示例9: getId

@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Column(name = "harvest_specimen_id", nullable = false)
@Access(value = AccessType.PROPERTY)
@Override
public Long getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:HarvestSpecimen.java

示例10: getId

@Override
@Id
@Access(value = AccessType.PROPERTY)
@Column(name = "gid", nullable = false)
public Integer getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:7,代碼來源:GISHirvitalousalue.java

示例11: getId

@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Column(name = "harvest_permit_contact_person_id", nullable = false)
@Access(value = AccessType.PROPERTY)
@Override
public Long getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:HarvestPermitContactPerson.java

示例12: getId

@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Column(name = ID_COLUMN_NAME, nullable = false)
@Access(value = AccessType.PROPERTY)
@Override
public Long getId() {
    return id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:SrvaSpecimen.java

示例13: getId

@Override
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Access(value = AccessType.PROPERTY)
@Column(name = ID_COLUMN_NAME, nullable = false)
public Long getId() {
    return this.id;
}
 
開發者ID:suomenriistakeskus,項目名稱:oma-riista-web,代碼行數:8,代碼來源:JHTTraining.java

示例14: getDateRangeInt

@SuppressWarnings("unused")
@Access(AccessType.PROPERTY)
@Column(name = Table.Column.DATE_RANGE_TYPE)
@JsonIgnore
public Integer getDateRangeInt() {
    return dateRange == null ? null : dateRange.getId();
}
 
開發者ID:hpe-idol,項目名稱:find,代碼行數:7,代碼來源:SavedSearch.java

示例15: getMagFilmeAsString

@Column(length = 1024)
@Access(AccessType.PROPERTY)
public String getMagFilmeAsString() {
	StringBuffer res = new StringBuffer();
	Set<Filme> set = getMagFilme();
	if (set != null) {
		for (Filme f : set) {
			if (res.length() > 0) {
				res.append(",");
			}
			res.append(f.name());
		}
	}
	return res.toString();
}
 
開發者ID:akquinet,項目名稱:vaadinator,代碼行數:15,代碼來源:Address.java


注:本文中的javax.persistence.AccessType.PROPERTY屬性示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。