Tabnine Logo
PersistentEntity.getCompositeIdentity
Code IndexAdd Tabnine to your IDE (free)

How to use
getCompositeIdentity
method
in
org.grails.datastore.mapping.model.PersistentEntity

Best Java code snippets using org.grails.datastore.mapping.model.PersistentEntity.getCompositeIdentity (Showing top 3 results out of 315)

origin: org.grails/grails-datastore-gorm-hibernate-core

private int calculateForeignKeyColumnCount(PersistentEntity refDomainClass, String[] propertyNames) {
  int expectedForeignKeyColumnLength = 0;
  for (String propertyName : propertyNames) {
    PersistentProperty referencedProperty = refDomainClass.getPropertyByName(propertyName);
    if(referencedProperty instanceof ToOne) {
      ToOne toOne = (ToOne) referencedProperty;
      PersistentProperty[] compositeIdentity = toOne.getAssociatedEntity().getCompositeIdentity();
      if(compositeIdentity != null) {
        expectedForeignKeyColumnLength += compositeIdentity.length;
      }
      else {
        expectedForeignKeyColumnLength++;
      }
    }
    else {
      expectedForeignKeyColumnLength++;
    }
  }
  return expectedForeignKeyColumnLength;
}
origin: org.grails/grails-datastore-core

PersistentProperty[] composite = entity.getCompositeIdentity();
if(composite != null) {
  for (PersistentProperty property : composite) {
origin: org.grails/grails-datastore-gorm-hibernate-core

PersistentProperty[] compositeIdentity = toOne.getAssociatedEntity().getCompositeIdentity();
if(compositeIdentity != null) {
  for (PersistentProperty cip : compositeIdentity) {
org.grails.datastore.mapping.modelPersistentEntitygetCompositeIdentity

Javadoc

The composite id

Popular methods of PersistentEntity

  • getJavaClass
  • getIdentity
    Returns the identity of the instance
  • getMapping
    Defines the mapping between this persistent entity and an external form
  • getPropertyByName
    Obtains a PersistentProperty instance by name
  • getName
    The entity name including any package prefix
  • getPersistentProperties
    A list of properties to be persisted
  • getVersion
    Returns the version property.
  • isMultiTenant
  • getAssociations
    A list of the associations for this entity. This is typically a subset of the list returned by #getP
  • getMappingContext
    Obtains the MappingContext where this PersistentEntity is defined
  • getReflector
  • getTenantId
  • getReflector,
  • getTenantId,
  • isInitialized,
  • isOwningEntity,
  • isRoot,
  • isVersioned,
  • addOwner,
  • getDecapitalizedName,
  • getDiscriminator

Popular in Java

  • Creating JSON documents from java classes using gson
  • runOnUiThread (Activity)
  • getSystemService (Context)
  • notifyDataSetChanged (ArrayAdapter)
  • Container (java.awt)
    A generic Abstract Window Toolkit(AWT) container object is a component that can contain other AWT co
  • BigInteger (java.math)
    An immutable arbitrary-precision signed integer.FAST CRYPTOGRAPHY This implementation is efficient f
  • ResultSet (java.sql)
    An interface for an object which represents a database table entry, returned as the result of the qu
  • SQLException (java.sql)
    An exception that indicates a failed JDBC operation. It provides the following information about pro
  • Cipher (javax.crypto)
    This class provides access to implementations of cryptographic ciphers for encryption and decryption
  • JFrame (javax.swing)
  • Github Copilot alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now