Class Content.Smart

    • Constructor Detail

      • Smart

        public Smart​(Content cont)
        Public ctor.
        Parameters:
        cont - Content
    • Method Detail

      • size

        public int size()
                 throws IOException
        Get its size.
        Returns:
        Size content
        Throws:
        IOException - If it fails
      • sha

        public String sha()
                   throws IOException
        Get its sha hash.
        Returns:
        Sha hash of content
        Throws:
        IOException - If there is any I/O problem
      • url

        public URL url()
                throws IOException
        Get its URL.
        Returns:
        URL of content
        Throws:
        IOException - If there is any I/O problem
      • htmlUrl

        public URL htmlUrl()
                    throws IOException
        Get its HTML URL.
        Returns:
        URL of content
        Throws:
        IOException - If there is any I/O problem
      • gitUrl

        public URL gitUrl()
                   throws IOException
        Get its GIT URL.
        Returns:
        URL of content
        Throws:
        IOException - If there is any I/O problem
      • content

        public String content()
                       throws IOException
        Get its encoded content.
        Returns:
        Base64 encoded content
        Throws:
        IOException - If there is any I/O problem
      • decoded

        public byte[] decoded()
                       throws IOException
        Get its decoded content.
        Returns:
        Decoded content
        Throws:
        IOException - If there is any I/O problem
      • patch

        public void patch​(javax.json.JsonObject json)
                   throws IOException
        Description copied from interface: JsonPatchable
        Patch using this JSON object.
        Specified by:
        patch in interface JsonPatchable
        Parameters:
        json - JSON object
        Throws:
        IOException - If there is any I/O problem
      • json

        public javax.json.JsonObject json()
                                   throws IOException
        Description copied from interface: JsonReadable
        Describe it in a JSON object.
        Specified by:
        json in interface JsonReadable
        Returns:
        JSON object
        Throws:
        IOException - If there is any I/O problem
      • repo

        public Repo repo()
        Description copied from interface: Content
        Repository we're in.
        Specified by:
        repo in interface Content
        Returns:
        Repo
      • path

        public String path()
        Description copied from interface: Content
        Get its path name.
        Specified by:
        path in interface Content
        Returns:
        The path name