本文整理汇总了Java中org.apache.isis.applib.annotation.Property类的典型用法代码示例。如果您正苦于以下问题:Java Property类的具体用法?Java Property怎么用?Java Property使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Property类属于org.apache.isis.applib.annotation包,在下文中一共展示了Property类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getName
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@javax.jdo.annotations.NotPersistent
@Property(
domainEvent = NameDomainEvent.class,
editing = Editing.DISABLED
)
@PropertyLayout(
hidden=Where.OBJECT_FORMS
)
@MemberOrder(name="Id", sequence = "1")
public String getName() {
final StringBuilder buf = new StringBuilder();
if(getFamilyName() != null) {
if(getKnownAs() != null) {
buf.append(getKnownAs());
} else {
buf.append(getGivenName());
}
buf.append(' ')
.append(getFamilyName())
.append(" (").append(getUsername()).append(')');
} else {
buf.append(getUsername());
}
return buf.toString();
}
示例2: if
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@Action(
semantics = SemanticsOf.SAFE,
domainEvent = ActionDomainEvent.class
)
@ActionLayout(
contributed = Contributed.AS_ASSOCIATION
)
@Property(
)
@PropertyLayout(
hidden=Where.REFERENCES_PARENT
)
@MemberOrder(name="Feature", sequence = "4")
public ApplicationFeatureViewModel $$(final ApplicationPermission permission) {
if(permission.getFeatureType() == null) {
return null;
}
final ApplicationFeatureId featureId = getFeatureId(permission);
return ApplicationFeatureViewModel.newViewModel(featureId, applicationFeatureRepository, container);
}
示例3: getParent
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@Property(
domainEvent = ParentDomainEvent.class
)
@PropertyLayout(hidden=Where.ALL_TABLES)
@MemberOrder(name = "Parent", sequence = "2.6")
public ApplicationFeatureViewModel getParent() {
final ApplicationFeatureId parentId;
parentId = getType() == ApplicationFeatureType.MEMBER
? getFeatureId().getParentClassId()
: getFeatureId().getParentPackageId();
if(parentId == null) {
return null;
}
final ApplicationFeature feature = applicationFeatureRepository.findFeature(parentId);
if (feature == null) {
return null;
}
final Class<?> cls = viewModelClassFor(parentId, applicationFeatureRepository);
return (ApplicationFeatureViewModel) container.newViewModelInstance(cls, parentId.asEncodedString());
}
示例4: getNotes
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@Property(
command = CommandReification.ENABLED,
publishing = Publishing.ENABLED,
domainEvent = NotesDomainEvent.class
)
public String getNotes() {
return notes;
}
示例5: getNombre
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@Property(editing = Editing.DISABLED)
@Column(allowsNull = "false",length = 40)
@MemberOrder(name="Equipo", sequence= "1")
public String getNombre()
{
return nombre;
}
示例6: complete
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@Action(
semantics = SemanticsOf.SAFE,
hidden = Where.ALL_TABLES
)
@ActionLayout(
describedAs = "The relative priority of this item compared to others not yet complete (using 'due by' date)",
contributed = Contributed.AS_ASSOCIATION
)
@Property(
editing = Editing.DISABLED,
editingDisabledReason = "Relative priority, derived from due date"
)
public Integer $$() {
return queryResultsCache.execute(() -> {
if(toDoItem.isComplete()) {
return null;
}
// sort items, then locate this one
int i=1;
for (final ToDoItem each : relativePriorityService.sortedNotYetComplete()) {
if(each == toDoItem) {
return i;
}
i++;
}
return null;
}, ToDoItem_relativePriority.class, "relativePriority", toDoItem);
}
示例7: getLocation
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@Property(
//ISIS-1138: Location value type not parsed from string, so fails to locate constructor
//domainEvent = LocationDomainEvent.class,
optionality = Optionality.OPTIONAL
)
public Location getLocation() {
return locationLatitude != null && locationLongitude != null? new Location(locationLatitude, locationLongitude): null;
}
示例8: getType
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@javax.jdo.annotations.Column(allowsNull="false", length=20)
@javax.jdo.annotations.Persistent
@Property(
domainEvent = TypeDomainEvent.class
)
@Override
public SettingType getType() {
return super.getType();
}
示例9: getName
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@Property(
mustSatisfy = CannotContainSpaces.class
)
@Column(allowsNull="false")
@Title(sequence="1")
public String getName() {
return name;
}
示例10: getDescription
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@Property(
mustSatisfy = CannotContainSpacesTr.class
)
@Column(allowsNull="true")
public String getDescription() {
return description;
}
示例11: getType
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
/**
* Combines {@link #getFeatureType() feature type} and member type.
*/
@Property(
domainEvent = TypeDomainEvent.class,
editing = Editing.DISABLED
)
@PropertyLayout(typicalLength=ApplicationPermission.TYPICAL_LENGTH_TYPE)
@MemberOrder(name="Feature", sequence = "5")
public String getType() {
final Enum<?> e = getFeatureType() != ApplicationFeatureType.MEMBER ? getFeatureType() : getMemberType();
return e != null ? e.name(): null;
}
示例12: getKey
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@javax.jdo.annotations.Column(length=128)
@javax.jdo.annotations.PrimaryKey
@Property(
domainEvent = KeyDomainEvent.class
)
@Title(sequence="10")
@Override
public String getKey() {
return super.getKey();
}
示例13: getDescription
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@javax.jdo.annotations.Column(allowsNull="false", length=100)
@Property(
regexPattern = "\\w[@&:\\-\\,\\.\\+ \\w]*"
)
@PropertyLayout(
typicalLength = 50
)
public String getDescription() {
return description;
}
示例14: getKey
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@javax.jdo.annotations.Column(length=128)
@javax.jdo.annotations.PrimaryKey
@Property(
domainEvent = KeyDomainEvent.class
)
public String getKey() {
return super.getKey();
}
示例15: getDescription
import org.apache.isis.applib.annotation.Property; //导入依赖的package包/类
@javax.jdo.annotations.Column(length=JdoColumnLength.DESCRIPTION)
@javax.jdo.annotations.Persistent
@Property(
domainEvent=DescriptionDomainEvent.class
)
@Override
public String getDescription() {
return super.getDescription();
}