Class ProtectionEntry

java.lang.Object
com.perforce.p4java.impl.generic.core.MapEntry
com.perforce.p4java.impl.generic.admin.ProtectionEntry
All Implemented Interfaces:
IProtectionEntry, IMapEntry

public class ProtectionEntry extends MapEntry implements IProtectionEntry
Default IProtectionEntry implementation class.

Note that the order of this protection entry in the protections table is part of the protection entry key when pass to the server for updating the protections table.

When exclusionary mappings are used, order is relevant: the exclusionary mapping overrides any matching protections listed above it in the table. No matter what access level is being denied in the exclusionary protection, all the access levels for the matching users, files, and IP addresses are denied.

 Protections0: super user p4java * //depot/...
 Protections1: write group p4users * //depot/project1/...
 Protections2: write group p4users * -//depot/project1/build/...
 Protections3: read user p4jtestuser * //depot/...
 Protections4: read user p4jtestuser * -//depot/topsecret/...
 
  • Constructor Details

    • ProtectionEntry

      public ProtectionEntry()
      Default constructor -- sets all fields to null, zero, or false.
    • ProtectionEntry

      public ProtectionEntry(int order, String mode, boolean group, String host, String name, String path, boolean pathExcluded)
      Explicit-value constructor.
      Parameters:
      order - order
      mode - mode
      group - group
      host - host
      name - name
      path - path
      pathExcluded - pathExcluded
    • ProtectionEntry

      public ProtectionEntry(Map<String,Object> map, int order)
      Constructs a ProtectionEntry from the passed-in map; this map must have come from a Perforce IServer method call or it may fail. If map is null, equivalent to calling the default constructor.
      Parameters:
      map - map
      order - order
  • Method Details