Class PathImpl

  • All Implemented Interfaces:
    Path

    public class PathImpl
    extends java.lang.Object
    implements Path
    Basic implementation of a Web Script Path Used for package & url trees.
    Author:
    davidc
    • Constructor Summary

      Constructors 
      Constructor Description
      PathImpl​(java.lang.String path)
      Construct
    • Constructor Detail

      • PathImpl

        public PathImpl​(java.lang.String path)
        Construct
        Parameters:
        path - String
    • Method Detail

      • concatPath

        public static java.lang.String concatPath​(java.lang.String path1,
                                                  java.lang.String path2)
        Helper to concatenate paths
        Parameters:
        path1 - String
        path2 - String
        Returns:
        concatenated path
      • createChildPath

        public PathImpl createChildPath​(java.lang.String path)
        Create a Child Path
        Parameters:
        path - child path name
        Returns:
        child path
      • addScript

        public void addScript​(WebScript script)
        Associate Web Script with Path
        Parameters:
        script - WebScript
      • getChildren

        public Path[] getChildren()
        Description copied from interface: Path
        Gets the child paths
        Specified by:
        getChildren in interface Path
        Returns:
        child paths
      • getScripts

        public WebScript[] getScripts()
        Description copied from interface: Path
        Gets Web Scripts associated with this path
        Specified by:
        getScripts in interface Path
        Returns:
        web scripts
      • getName

        public java.lang.String getName()
        Description copied from interface: Path
        Gets the name of the path (last path segment)
        Specified by:
        getName in interface Path
        Returns:
        name
      • getParent

        public Path getParent()
        Description copied from interface: Path
        Gets the parent path
        Specified by:
        getParent in interface Path
        Returns:
        path
      • getPath

        public java.lang.String getPath()
        Description copied from interface: Path
        Gets the full path
        Specified by:
        getPath in interface Path
        Returns:
        path
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object