alfrescoalfresco-sharecontent-model

What is the purpose of <role> within association definition in a content model?


I noticed this within the person model (Didn't pick up on it the first time):

 <associations>
    <association name="cm:avatar">
       <source>
          <role>cm:avatarOf</role> <!-- What is the purpose of this?? -->
          <mandatory>false</mandatory>
          <many>false</many>
       </source>
       <target>
          <class>cm:content</class>
          <role>cm:hasAvatar</role>
          <mandatory>false</mandatory>
          <many>false</many>
       </target>
    </association>
 </associations>

I am duplicating this association for my own model and would like to know it's significance of this element within associations.


Solution

  • The info is informational only, the value can even be retrieved via the JavaScript API. Information can be found here: https://issues.alfresco.com/jira/browse/MNT-7403