# Class BaseIdProperty<E>

java.lang.Object
org.apache.cayenne.exp.property.BaseProperty<E>
org.apache.cayenne.exp.property.BaseIdProperty<E>

All Implemented Interfaces:
  `IdProperty<E>, Property<E>`

public class BaseIdProperty<E> extends BaseProperty<E> implements IdProperty<E>
Property that represents non-numeric PK

Since:
  4.2

- ## Field Summary

  ### Fields inherited from class BaseProperty

  `expressionSupplier, path, type`

- ## Constructor Summary

  Constructors
  Modifier
  Constructor
  Description
  `protected`
  `BaseIdProperty(String attribute, CayennePath path, String entityName, Class<? super E> type)`
  Constructs a new property with the given name and expression

- ## Method Summary

  Modifier and Type
  Method
  Description
  `String`
  `getAttributeName()`
  `String`
  `getEntityName()`

  ### Methods inherited from class BaseProperty

  `aggregate, alias, asc, ascInsensitive, ascInsensitives, ascs, count, countDistinct, desc, descInsensitive, descInsensitives, descs, enclosing, eq, eq, equals, function, function, getAlias, getExpression, getFrom, getFromAll, getName, getPath, getType, hashCode, in, in, in, isFalse, isNotNull, isNull, isTrue, ne, ne, nin, nin, nin, operator, operator, setIn, setInAll`

  ### Methods inherited from class Object

  `clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

  ### Methods inherited from interface IdProperty

  `eq`

  ### Methods inherited from interface Property

  `getAlias, getExpression, getName, getPath, getType`

- ## Constructor Details

  - ### BaseIdProperty

    protected BaseIdProperty(String attribute, CayennePath path, String entityName, Class<? super E> type)
    Constructs a new property with the given name and expression
    Parameters:
      `attribute` - PK attribute name (optional, can be omitted for single PK entity)
      `path` - cayenne path (optional, can be omitted for ID of the root)
      `entityName` - name of the entity (mandatory)
      `type` - of the property (mandatory)
    See Also:
      - `PropertyFactory.createBaseId(String, CayennePath, String, Class)`

- ## Method Details

  - ### getEntityName

    public String getEntityName()
    Specified by:
      `getEntityName` in interface `IdProperty<E>`

  - ### getAttributeName

    public String getAttributeName()
    Specified by:
      `getAttributeName` in interface `IdProperty<E>`