Package io.inversion
Class Property
- java.lang.Object
-
- io.inversion.Property
-
- All Implemented Interfaces:
java.io.Serializable
public final class Property extends java.lang.Object implements java.io.Serializable- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanautoGeneratedprotected Collectioncollectionprotected java.lang.StringcolumnNameprotected java.lang.Stringdescriptionprotected booleandocumentedprotected booleanexcludeprotected java.lang.Stringhintprotected java.lang.StringjsonTypeprotected java.lang.Stringnameprotected booleannullableprotected PropertypkIf this Property is a foreign key, this will be populated with the referenced primary key from the referred Collectionprotected booleanreadOnlyprotected java.lang.Stringregexprotected booleanrequiredprotected booleanrevisionColumnprotected booleantimestampColumnprotected java.lang.Stringtype
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object object)CollectiongetCollection()java.lang.StringgetColumnName()java.lang.StringgetDescription()java.lang.StringgetHint()java.lang.StringgetJsonName()java.lang.StringgetJsonType()java.lang.StringgetName()PropertygetPk()java.lang.StringgetRegex()java.lang.StringgetType()booleanisAutoGenerated()booleanisDocumented()booleanisExclude()booleanisFk()booleanisNullable()booleanisReadOnly()booleanisRequired()booleanisRevisionColumn()booleanisTimestampColumn()voidsetCollection(Collection collection)java.lang.StringtoString()PropertywithAutoGenerated(boolean autoGenerated)PropertywithCollection(Collection collection)PropertywithColumnName(java.lang.String name)PropertywithDescription(java.lang.String description)PropertywithDocumented(boolean documented)PropertywithExclude(boolean exclude)PropertywithHint(java.lang.String hint)PropertywithJsonName(java.lang.String name)PropertywithJsonType(java.lang.String jsonType)PropertywithName(java.lang.String name)PropertywithNullable(boolean nullable)PropertywithPk(Property primaryKey)PropertywithReadOnly(boolean readOnly)PropertywithRegex(java.lang.String regex)PropertywithRequired(boolean required)PropertywithRevisionColumn(boolean revisionColumn)PropertywithTimestampColumn(boolean timestampColumn)PropertywithType(java.lang.String type)
-
-
-
Field Detail
-
name
protected java.lang.String name
-
columnName
protected java.lang.String columnName
-
description
protected java.lang.String description
-
type
protected java.lang.String type
-
nullable
protected boolean nullable
-
readOnly
protected boolean readOnly
-
autoGenerated
protected boolean autoGenerated
-
required
protected boolean required
-
jsonType
protected java.lang.String jsonType
-
regex
protected java.lang.String regex
-
documented
protected boolean documented
-
revisionColumn
protected boolean revisionColumn
-
timestampColumn
protected boolean timestampColumn
-
hint
protected java.lang.String hint
-
exclude
protected boolean exclude
-
pk
protected Property pk
If this Property is a foreign key, this will be populated with the referenced primary key from the referred Collection
-
collection
protected Collection collection
-
-
Method Detail
-
setCollection
public void setCollection(Collection collection)
-
equals
public boolean equals(java.lang.Object object)
- Overrides:
equalsin classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
withDescription
public Property withDescription(java.lang.String description)
-
getDescription
public java.lang.String getDescription()
-
getPk
public Property getPk()
- Returns:
- the primaryKey
-
withPk
public Property withPk(Property primaryKey)
- Parameters:
primaryKey- the primaryKey to set- Returns:
- this
-
isFk
public boolean isFk()
-
getColumnName
public java.lang.String getColumnName()
- Returns:
- the name
-
withColumnName
public Property withColumnName(java.lang.String name)
- Parameters:
name- the name to set- Returns:
- this
-
getJsonName
public java.lang.String getJsonName()
- Returns:
- the name
-
getName
public java.lang.String getName()
-
withJsonName
public Property withJsonName(java.lang.String name)
- Parameters:
name- the name to set- Returns:
- this
-
withName
public Property withName(java.lang.String name)
-
getType
public java.lang.String getType()
- Returns:
- the type
-
withType
public Property withType(java.lang.String type)
- Parameters:
type- the type to set- Returns:
- this
-
getCollection
public Collection getCollection()
- Returns:
- the collection that owns this property
-
withCollection
public Property withCollection(Collection collection)
- Parameters:
collection- the Collection the Property belongs to- Returns:
- this
-
getHint
public java.lang.String getHint()
- Returns:
- the hint
-
withHint
public Property withHint(java.lang.String hint)
- Parameters:
hint- the hint to set- Returns:
- this
-
isNullable
public boolean isNullable()
-
withNullable
public Property withNullable(boolean nullable)
-
isExclude
public boolean isExclude()
-
withExclude
public Property withExclude(boolean exclude)
-
isReadOnly
public boolean isReadOnly()
-
withReadOnly
public Property withReadOnly(boolean readOnly)
-
isAutoGenerated
public boolean isAutoGenerated()
-
withAutoGenerated
public Property withAutoGenerated(boolean autoGenerated)
-
isRequired
public boolean isRequired()
-
withRequired
public Property withRequired(boolean required)
-
withRegex
public Property withRegex(java.lang.String regex)
-
isDocumented
public boolean isDocumented()
-
withDocumented
public Property withDocumented(boolean documented)
-
getRegex
public java.lang.String getRegex()
-
isRevisionColumn
public boolean isRevisionColumn()
-
withRevisionColumn
public Property withRevisionColumn(boolean revisionColumn)
-
isTimestampColumn
public boolean isTimestampColumn()
-
withTimestampColumn
public Property withTimestampColumn(boolean timestampColumn)
-
withJsonType
public Property withJsonType(java.lang.String jsonType)
-
getJsonType
public java.lang.String getJsonType()
-
-