Record Class RemoteFieldReadAccess.RuleTarget

java.lang.Object
java.lang.Record
fr.becpg.repo.entity.remote.extractor.RemoteFieldReadAccess.RuleTarget
Record Components:
nodeType - the node type
ruleScope - the node, when it carries its own rules
typeKey - the identity of the rules in force for the type
ruledFields - the fields a rule is set on
Enclosing class:
RemoteFieldReadAccess

private static record RemoteFieldReadAccess.RuleTarget(org.alfresco.service.namespace.QName nodeType, Optional<org.alfresco.service.cmr.repository.NodeRef> ruleScope, String typeKey, Set<org.alfresco.service.namespace.QName> ruledFields) extends Record
The rules a field of a node is checked against: its type, the node itself when it has rules of its own, and the fields those rules are set on. Resolved once per node, so that reading a field costs a set lookup.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private final org.alfresco.service.namespace.QName
    The field for the nodeType record component.
    private final Set<org.alfresco.service.namespace.QName>
    The field for the ruledFields record component.
    private final Optional<org.alfresco.service.cmr.repository.NodeRef>
    The field for the ruleScope record component.
    private final String
    The field for the typeKey record component.
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    private
    RuleTarget(org.alfresco.service.namespace.QName nodeType, Optional<org.alfresco.service.cmr.repository.NodeRef> ruleScope, String typeKey, Set<org.alfresco.service.namespace.QName> ruledFields)
    Creates an instance of a RuleTarget record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    private String
    cacheKey(org.alfresco.service.namespace.QName fieldName)
     
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    org.alfresco.service.namespace.QName
    Returns the value of the nodeType record component.
    Set<org.alfresco.service.namespace.QName>
    Returns the value of the ruledFields record component.
    Optional<org.alfresco.service.cmr.repository.NodeRef>
    Returns the value of the ruleScope record component.
    final String
    Returns a string representation of this record class.
    Returns the value of the typeKey record component.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Field Details

    • nodeType

      private final org.alfresco.service.namespace.QName nodeType
      The field for the nodeType record component.
    • ruleScope

      private final Optional<org.alfresco.service.cmr.repository.NodeRef> ruleScope
      The field for the ruleScope record component.
    • typeKey

      private final String typeKey
      The field for the typeKey record component.
    • ruledFields

      private final Set<org.alfresco.service.namespace.QName> ruledFields
      The field for the ruledFields record component.
  • Constructor Details

    • RuleTarget

      private RuleTarget(org.alfresco.service.namespace.QName nodeType, Optional<org.alfresco.service.cmr.repository.NodeRef> ruleScope, String typeKey, Set<org.alfresco.service.namespace.QName> ruledFields)
      Creates an instance of a RuleTarget record class.
      Parameters:
      nodeType - the value for the nodeType record component
      ruleScope - the value for the ruleScope record component
      typeKey - the value for the typeKey record component
      ruledFields - the value for the ruledFields record component
  • Method Details

    • cacheKey

      private String cacheKey(org.alfresco.service.namespace.QName fieldName)
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • nodeType

      public org.alfresco.service.namespace.QName nodeType()
      Returns the value of the nodeType record component.
      Returns:
      the value of the nodeType record component
    • ruleScope

      public Optional<org.alfresco.service.cmr.repository.NodeRef> ruleScope()
      Returns the value of the ruleScope record component.
      Returns:
      the value of the ruleScope record component
    • typeKey

      public String typeKey()
      Returns the value of the typeKey record component.
      Returns:
      the value of the typeKey record component
    • ruledFields

      public Set<org.alfresco.service.namespace.QName> ruledFields()
      Returns the value of the ruledFields record component.
      Returns:
      the value of the ruledFields record component