Class AssetReference

    • Constructor Detail

      • AssetReference

        protected AssetReference()
        Creates an Asset Reference property with no name and with a null value.
      • AssetReference

        public AssetReference​(Atom propertyAtom)
        Creates an Asset Reference property with the specified name with a null value.
        Parameters:
        propertyAtom - the property atom.
      • AssetReference

        public AssetReference​(Atom propertyAtom,
                              java.lang.String newValue)
        Creates an Asset Reference property with the specified name and value.
        Parameters:
        propertyAtom - the property atom.
        newValue - the new string value for the property.
    • Method Detail

      • setResolvedURL

        public FileURIPropCnr setResolvedURL​(java.net.URL url,
                                             long modificationTime,
                                             long size)
        Sets the resolved URL in the Jar file.
        Parameters:
        url - The file URL.
        modificationTime - Last modification time.
        size - Size in bytes.
        Returns:
        The FileURIPropCnr instance.
      • getFileURL

        public java.net.URL getFileURL()
        Gets the file URL for this reference.

        The method first attempts to use the resolved mechanism of getting the VirtualSpace. If this has failed or has not been resolved yet, the property tree will be used to search for it. The latter is, of course, slower.

        Returns:
        The URL instance, or null if not found.
      • getFileURIPropCnr

        public FileURIPropCnr getFileURIPropCnr()
        For the Designer, gets the File property for the reference.

        The method first attempts to use the resolved mechanism of getting the VirtualSpace. If this has failed or has not been resolved yet, the property tree will be used to search for it. The latter is, of course, slower.

        Returns:
        The FileURIPropCnr instance, or null if not found.
      • getFileURIPropCnr

        public FileURIPropCnr getFileURIPropCnr​(GProp<?> anyPropInTree)
        For the Designer, gets the File property for the reference.

        The method first attempts to use the resolved mechanism of getting the VirtualSpace. If this has failed or has not been resolved yet, the property tree will be used to search for it. The latter is, of course, slower.

        Parameters:
        anyPropInTree - Any property in tree if this instance is not attached.
        Returns:
        The FileURIPropCnr instance, or null if not found.
      • validateReferenceScope

        protected java.lang.String validateReferenceScope​(FileURIPropCnr target)
        Called when the a property container has been renamed or moved in order to perform validation of the reference, e.g. if a base property has been moved out of scope. The implementor can assign or clear property errors by returning the error string.
        Overrides:
        validateReferenceScope in class AbstractReference<FileURIPropCnr>
        Parameters:
        target - Target reference to validate the scope of, i.e. the referenced property.
        Returns:
        The error message, or null for valid. Default implementation returns null.
      • getClientResourceString

        public java.lang.String getClientResourceString()
        Gets the Client resource string in form "module$/path/filename.ext".
        Returns:
        null If not valid.