Class ImmutableProjectResource

java.lang.Object
com.inductiveautomation.ignition.common.project.resource.ImmutableProjectResource
All Implemented Interfaces:
ProjectResource, Serializable

public class ImmutableProjectResource extends Object implements ProjectResource
See Also:
  • Method Details

    • getProjectName

      public String getProjectName()
      Description copied from interface: ProjectResource
      Get the name of the Project this resource belongs to.
      Specified by:
      getProjectName in interface ProjectResource
      Returns:
      the name of the Project this resource belongs to.
    • getResourcePath

      public ResourcePath getResourcePath()
      Specified by:
      getResourcePath in interface ProjectResource
    • getApplicationScope

      public int getApplicationScope()
      Description copied from interface: ProjectResource
      Get the application scope of this resource.
      Specified by:
      getApplicationScope in interface ProjectResource
      Returns:
      the application scope of this resource.
      See Also:
    • getDocumentation

      public String getDocumentation()
      Specified by:
      getDocumentation in interface ProjectResource
    • getVersion

      public int getVersion()
      Description copied from interface: ProjectResource
      Get the version of this resource.

      The version number is not intended to track mutations to the resource like the legacy edit count, but rather, its interpretation and use is for the entities this resource type belongs to and so it can be used to reason about the contents of the resource, e.g. to distinguish between serialization formats.

      Specified by:
      getVersion in interface ProjectResource
      Returns:
      the version of this resource.
    • isFolder

      public boolean isFolder()
      Specified by:
      isFolder in interface ProjectResource
      Returns:
      true if this resource is a folder.
    • isLocked

      public boolean isLocked()
      Specified by:
      isLocked in interface ProjectResource
      Returns:
      true if this resource is OEM locked.
    • isRestricted

      public boolean isRestricted()
      Specified by:
      isRestricted in interface ProjectResource
      Returns:
      true if this resource is restricted to users of a certain role. Formerly known as "protected".
    • isOverridable

      public boolean isOverridable()
      Specified by:
      isOverridable in interface ProjectResource
      Returns:
      true if this resource can be overridden by child projects.
    • getData

      public byte[] getData(String key)
      Specified by:
      getData in interface ProjectResource
    • getDataKeys

      @Nonnull public com.google.common.collect.ImmutableSet<String> getDataKeys()
      Description copied from interface: ProjectResource
      Get an immutable view of the data key set.
      Specified by:
      getDataKeys in interface ProjectResource
      Returns:
      an immutable view of the data key set.
    • getAttributes

      @Nonnull public com.google.common.collect.ImmutableMap<String,com.inductiveautomation.ignition.common.gson.JsonElement> getAttributes()
      Description copied from interface: ProjectResource
      Get an immutable view of the attributes map.
      Specified by:
      getAttributes in interface ProjectResource
      Returns:
      an immutable view of the attributes map.
    • getContentDigest

      public byte[] getContentDigest()
      Description copied from interface: ProjectResource
      Get the SHA-256 digest of the content of this resource. This does not include the project name or any part of the path to this resource, but rather, it's a representation of the contents of the folder on disk.

      Any changes to any of the resource contents of that folder shall result in a change to the content digest.

      Specified by:
      getContentDigest in interface ProjectResource
      Returns:
      the SHA-256 digest of the content of this resource.
      See Also:
    • getResourceSignature

      public ResourceSignature getResourceSignature()
      Description copied from interface: ProjectResource
      Get the ResourceSignature for this resource.
      Specified by:
      getResourceSignature in interface ProjectResource
      Returns:
      the ResourceSignature for this resource.
    • getResourceId

      public ProjectResourceId getResourceId()
      Specified by:
      getResourceId in interface ProjectResource
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object