Class GHObject

    • Field Detail

      • responseHeaderFields

        protected transient Map<String,​List<String>> responseHeaderFields
        Capture response HTTP headers on the state object.
    • Method Detail

      • setResponseHeaderFields

        protected void setResponseHeaderFields​(@CheckForNull
                                               org.kohsuke.github.GitHubResponse.ResponseInfo responseInfo)
        Called by Jackson
        Parameters:
        responseInfo - the GitHubResponse.ResponseInfo to get headers from.
      • getResponseHeaderFields

        @CheckForNull
        @Deprecated
        public Map<String,​List<String>> getResponseHeaderFields()
        Deprecated.
        Returns the HTTP response headers given along with the state of this object.

        Some of the HTTP headers have nothing to do with the object, for example "Cache-Control" and others are different depending on how this object was retrieved.

        This method was added as a kind of hack to allow the caller to retrieve OAuth scopes and such. Use with caution. The method might be removed in the future.

        Returns:
        a map of header names to value lists
      • getUrl

        @WithBridgeMethods(value=java.lang.String.class,
                           adapterMethod="urlToString")
        public URL getUrl()
        Gets url.
        Returns:
        API URL of this object.
      • getHtmlUrl

        @WithBridgeMethods(value=java.lang.String.class,
                           adapterMethod="urlToString")
        public abstract URL getHtmlUrl()
                                throws IOException
        Gets html url.
        Returns:
        URL of this object for humans, which renders some HTML.
        Throws:
        IOException - on error
      • getUpdatedAt

        public Date getUpdatedAt()
                          throws IOException
        When was this resource last updated?
        Returns:
        updated date
        Throws:
        IOException - on error
      • getNodeId

        public String getNodeId()
        Get Global node_id from Github object.
        Returns:
        Global Node ID.
        See Also:
        Using Global Node IDs
      • getId

        @WithBridgeMethods(value={java.lang.String.class,int.class},
                           adapterMethod="longToStringOrInt")
        public long getId()
        Gets id.
        Returns:
        Unique ID number of this resource.
      • toString

        public String toString()
        String representation to assist debugging and inspection. The output format of this string is not a committed part of the API and is subject to change.
        Overrides:
        toString in class Object