Class RepositoryFile


  • public class RepositoryFile
    extends java.lang.Object
    • Constructor Detail

      • RepositoryFile

        public RepositoryFile()
    • Method Detail

      • getFileName

        public java.lang.String getFileName()
      • setFileName

        public void setFileName​(java.lang.String fileName)
      • getFilePath

        public java.lang.String getFilePath()
      • setFilePath

        public void setFilePath​(java.lang.String filePath)
      • getSize

        public java.lang.Integer getSize()
      • setSize

        public void setSize​(java.lang.Integer size)
      • getContent

        public java.lang.String getContent()
      • setContent

        public void setContent​(java.lang.String content)
      • getContentSha256

        public java.lang.String getContentSha256()
      • setContentSha256

        public void setContentSha256​(java.lang.String contentSha256)
      • getRef

        public java.lang.String getRef()
      • setRef

        public void setRef​(java.lang.String ref)
      • getBlobId

        public java.lang.String getBlobId()
      • setBlobId

        public void setBlobId​(java.lang.String blobId)
      • getCommitId

        public java.lang.String getCommitId()
      • setCommitId

        public void setCommitId​(java.lang.String commitId)
      • getLastCommitId

        public java.lang.String getLastCommitId()
      • setLastCommitId

        public void setLastCommitId​(java.lang.String lastCommitId)
      • getDecodedContentAsString

        public java.lang.String getDecodedContentAsString()
        Returns the content as a String, base64 decoding it if necessary. For binary files it is recommended to use getDecodedContentAsBytes()
        Returns:
        the content as a String, base64 decoding it if necessary
      • getDecodedContentAsBytes

        public byte[] getDecodedContentAsBytes()
        Returns the content as a byte array, decoding from base64 if necessary. For String content it is recommended to use getDecodedContent().
        Returns:
        the content as a byte array, decoding from base64 if necessary
      • encodeAndSetContent

        public void encodeAndSetContent​(java.lang.String content)
        Encodes the provided String using Base64 and sets it as the content. The encoding property of this instance will be set to base64.
        Parameters:
        content - the String content to encode and set as the base64 encoded String content
      • encodeAndSetContent

        public void encodeAndSetContent​(byte[] byteContent)
        Encodes the provided byte array using Base64 and sets it as the content. The encoding property of this instance will be set to base64.
        Parameters:
        byteContent - the byte[] content to encode and set as the base64 encoded String content
      • toString

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