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


Java Parameter類代碼示例

本文整理匯總了Java中org.hibernate.annotations.Parameter的典型用法代碼示例。如果您正苦於以下問題:Java Parameter類的具體用法?Java Parameter怎麽用?Java Parameter使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


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

示例1: getId

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@GenericGenerator(name = "generator", strategy = "foreign", parameters = @Parameter(name = "property", value = "user"))
@Id
@GeneratedValue(generator = "generator")
@Column(name = "id", unique = true, nullable = false)
public int getId() {
	return this.id;
}
 
開發者ID:PacktPublishing,項目名稱:Spring-MVC-Blueprints,代碼行數:8,代碼來源:Login.java

示例2: bindTypeDef

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
private static void bindTypeDef(TypeDef defAnn, Mappings mappings) {
	Properties params = new Properties();
	for ( Parameter param : defAnn.parameters() ) {
		params.setProperty( param.name(), param.value() );
	}

	if ( BinderHelper.isEmptyAnnotationValue( defAnn.name() ) && defAnn.defaultForType().equals( void.class ) ) {
		throw new AnnotationException(
				"Either name or defaultForType (or both) attribute should be set in TypeDef having typeClass " +
						defAnn.typeClass().getName()
		);
	}

	final String typeBindMessageF = "Binding type definition: %s";
	if ( !BinderHelper.isEmptyAnnotationValue( defAnn.name() ) ) {
		if ( LOG.isDebugEnabled() ) {
			LOG.debugf( typeBindMessageF, defAnn.name() );
		}
		mappings.addTypeDef( defAnn.name(), defAnn.typeClass().getName(), params );
	}
	if ( !defAnn.defaultForType().equals( void.class ) ) {
		if ( LOG.isDebugEnabled() ) {
			LOG.debugf( typeBindMessageF, defAnn.defaultForType().getName() );
		}
		mappings.addTypeDef( defAnn.defaultForType().getName(), defAnn.typeClass().getName(), params );
	}

}
 
開發者ID:lamsfoundation,項目名稱:lams,代碼行數:29,代碼來源:AnnotationBinder.java

示例3: setExplicitType

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
public void setExplicitType(Type typeAnn) {
	if ( typeAnn != null ) {
		explicitType = typeAnn.type();
		typeParameters.clear();
		for ( Parameter param : typeAnn.parameters() ) {
			typeParameters.setProperty( param.name(), param.value() );
		}
	}
}
 
開發者ID:lamsfoundation,項目名稱:lams,代碼行數:10,代碼來源:SimpleValueBinder.java

示例4: getId

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@GenericGenerator(name = "generator", strategy = "foreign", parameters = @Parameter(name = "property", value = "customerAccount"))
@Id
@GeneratedValue(generator = "generator")
@Column(name = "id", unique = true, nullable = false)
public Integer getId() {
	return this.id;
}
 
開發者ID:PacktPublishing,項目名稱:Spring-MVC-Blueprints,代碼行數:8,代碼來源:Login.java

示例5: getId

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@GenericGenerator(name = "generator", strategy = "foreign", parameters = @Parameter(name = "property", value = "invoice"))
@Id
@GeneratedValue(generator = "generator")
@Column(name = "id", unique = true, nullable = false)
public Integer getId() {
	return this.id;
}
 
開發者ID:PacktPublishing,項目名稱:Spring-MVC-Blueprints,代碼行數:8,代碼來源:InvoicedProducts.java

示例6: getStudentId

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@GenericGenerator(name = "generator", strategy = "foreign", parameters = @Parameter(name = "property", value = "tblstudents"))
@Id
@GeneratedValue(generator = "generator")
@Column(name = "studentID", unique = true, nullable = false)
public int getStudentId() {
	return this.studentId;
}
 
開發者ID:PacktPublishing,項目名稱:Spring-MVC-Blueprints,代碼行數:8,代碼來源:Tblgpa.java

示例7: getId

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@GenericGenerator(name = "generator", strategy = "foreign", parameters = @Parameter(name = "property", value = "customerInfo"))
@Id
@GeneratedValue(generator = "generator")
@Column(name = "id", unique = true, nullable = false)
public int getId() {
	return this.id;
}
 
開發者ID:PacktPublishing,項目名稱:Spring-MVC-Blueprints,代碼行數:8,代碼來源:Login.java

示例8: getId

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@Id
@Column(name = "ID", unique = true, nullable = false, length = 19)
@GeneratedValue(strategy = GenerationType.TABLE, generator = "table")
@GenericGenerator(name = "table", strategy = "org.hibernate.id.MultipleHiLoPerTableGenerator", parameters = {
		@Parameter(name = "max_lo", value = "5") })//增長級別為5,可根據並發級別適當調整
public Long getId() {
	return this.id;
}
 
開發者ID:summerDp,項目名稱:dpCms,代碼行數:9,代碼來源:Menu.java

示例9: getUserId

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@GenericGenerator(name = "generator", strategy = "foreign", parameters = @Parameter(name = "property", value = "user"))
@Id
@GeneratedValue(generator = "generator")
@Column(name = "user_id", unique = true, nullable = false)
public int getUserId() {
	return this.userId;
}
 
開發者ID:hadrsystems,項目名稱:nics-common,代碼行數:8,代碼來源:UserInfo.java

示例10: getGpa

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@Column(name = "gpa")
@Type(type = "com.eclecticlogic.pedal.provider.hibernate.ListType", parameters = {
        @Parameter(name = ArrayType.DIALECT_PRIMITIVE_NAME, value = PostgresqlArrayPrimitiveName.LONG),
        @Parameter(name = ArrayType.EMPTY_IS_NULL, value = "false") })
public List<Long> getGpa() {
    return gpa;
}
 
開發者ID:eclecticlogic,項目名稱:pedal-dialect,代碼行數:8,代碼來源:ExoticTypes.java

示例11: getCapitals

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@Column(name = "capitals")
@Type(type = "com.eclecticlogic.pedal.provider.hibernate.ListType", parameters = {
        @Parameter(name = ArrayType.DIALECT_PRIMITIVE_NAME, value = PostgresqlArrayPrimitiveName.STRING)})
@CopyEmptyAsNull
public List<String> getCapitals() {
    return capitals;
}
 
開發者ID:eclecticlogic,項目名稱:pedal-dialect,代碼行數:8,代碼來源:ExoticTypes.java

示例12: getExecuterInformationData

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@Column(name = "EXECUTER_INFORMATION_DATA", length = Integer.MAX_VALUE)
@Cascade(CascadeType.ALL)
@Type(type = "org.hibernate.type.SerializableToBlobType", parameters = @org.hibernate.annotations.Parameter(name = SerializableToBlobType.CLASS_NAME, value = "java.lang.Object"))
@OnDelete(action = OnDeleteAction.CASCADE)
public ExecuterInformationData getExecuterInformationData() {
    return executerInformationData;
}
 
開發者ID:ow2-proactive,項目名稱:scheduling,代碼行數:8,代碼來源:TaskData.java

示例13: getAddress

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@Column(name = "address", columnDefinition = "TEXT")
@Type(type = "com.yahoo.elide.datastores.hibernate3.usertypes.JsonType", parameters = {
        @Parameter(name = "class", value = "example.AddressFragment")
})
public AddressFragment getAddress() {
    return address;
}
 
開發者ID:yahoo,項目名稱:elide,代碼行數:8,代碼來源:Person.java

示例14: getAddress

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@Column(name = "address", columnDefinition = "TEXT")
@Type(type = "com.yahoo.elide.datastores.hibernate5.usertypes.JsonType", parameters = {
        @Parameter(name = "class", value = "example.AddressFragment")
})
public AddressFragment getAddress() {
    return address;
}
 
開發者ID:yahoo,項目名稱:elide,代碼行數:8,代碼來源:Person.java

示例15: getId

import org.hibernate.annotations.Parameter; //導入依賴的package包/類
@Override
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY, generator = "ancestrySequenceGenerator")
@GenericGenerator(name = "ancestrySequenceGenerator", strategy = "jeffaschenk.commons.touchpoint.model.dao.support.hibernate.PlatformSequenceGenerator",
        parameters = {@Parameter(name = "sequence", value = "ancestries_seq_id")})
public Integer getId() {
    return super.getId();
}
 
開發者ID:jaschenk,項目名稱:jeffaschenk-commons,代碼行數:9,代碼來源:Ancestry.java


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