Class NuxeoGroupJsonReader

All Implemented Interfaces:
Marshaller<NuxeoGroup>, Reader<NuxeoGroup>

@Setup(mode=SINGLETON, priority=2000) public class NuxeoGroupJsonReader extends EntityJsonReader<NuxeoGroup>
Convert Json as NuxeoGroup.

Format is (any additional json property is ignored):

 {
   "entity-type":"group",
   "groupname": "GROUP_NAME", <- deprecated, for backward compatibility
   "grouplabel": "GROUP_DISPLAY_NAME", <- deprecated, for backward compatibility
   "id": "GROUP_NAME",
   "memberUsers": [
     "USERNAME1",
     "USERNAME2",
     ...
   ],
   "memberGroups": [
     "GROUPNAME1",
     "GROUPNAME2",
     ...
   ]
 }
 
Since:
7.2
  • Constructor Details

    • NuxeoGroupJsonReader

      public NuxeoGroupJsonReader()
  • Method Details

    • readEntity

      protected NuxeoGroup readEntity(com.fasterxml.jackson.databind.JsonNode jn) throws IOException
      Description copied from class: EntityJsonReader
      Implement this method to read the entity.
      Specified by:
      readEntity in class EntityJsonReader<NuxeoGroup>
      Parameters:
      jn - A JsonNode pointing at the root of the json input.
      Returns:
      The parsed entity.
      Throws:
      IOException
    • readProperties

      protected void readProperties(DocumentModel groupModel, GroupConfig groupConfig, com.fasterxml.jackson.databind.JsonNode jn) throws IOException
      Throws:
      IOException
    • readMemberUsers

      protected void readMemberUsers(DocumentModel groupModel, GroupConfig groupConfig, com.fasterxml.jackson.databind.JsonNode jn)
    • readMemberGroups

      protected void readMemberGroups(DocumentModel groupModel, GroupConfig groupConfig, com.fasterxml.jackson.databind.JsonNode jn)
    • readParentGroups

      protected void readParentGroups(DocumentModel groupModel, GroupConfig groupConfig, com.fasterxml.jackson.databind.JsonNode jn)