Class GitLabRepository

java.lang.Object
com.mooltiverse.oss.nyx.services.gitlab.GitLabRepository
All Implemented Interfaces:
GitHostedRepository

public class GitLabRepository extends Object implements GitHostedRepository
A Git repository hosted on GitLab.
  • Method Details

    • getDefaultBranch

      public String getDefaultBranch()
      Returns the repository default branch.
      Specified by:
      getDefaultBranch in interface GitHostedRepository
      Returns:
      the repository default branch.
    • getDescription

      public String getDescription()
      Returns the repository description.
      Specified by:
      getDescription in interface GitHostedRepository
      Returns:
      the repository description.
    • getFullName

      public String getFullName()
      Returns the repository full name.
      Specified by:
      getFullName in interface GitHostedRepository
      Returns:
      the repository full name.
    • getHTTPURL

      public String getHTTPURL()
      Returns the repository HTTP URL.
      Specified by:
      getHTTPURL in interface GitHostedRepository
      Returns:
      the repository HTTP URL.
    • getSSHURL

      public String getSSHURL()
      Returns the repository SSH URL.
      Specified by:
      getSSHURL in interface GitHostedRepository
      Returns:
      the repository SSH URL.
    • getID

      public String getID()
      Returns the repository ID.
      Specified by:
      getID in interface GitHostedRepository
      Returns:
      the repository ID.
    • getName

      public String getName()
      Returns the repository name.
      Specified by:
      getName in interface GitHostedRepository
      Returns:
      the repository name.
    • toAttributeMap

      protected static Map<String,​Object> toAttributeMap(com.fasterxml.jackson.databind.JsonNode node)
      Reads all the attributes of the given object and puts them in the resulting map.
      Parameters:
      node - the node to read the attributes from
      Returns:
      the map with all the attributes from the given node
      Throws:
      NullPointerException - if the given node is null
    • toAttributeMaps

      protected static List<Map<String,​Object>> toAttributeMaps(com.fasterxml.jackson.databind.JsonNode node)
      Reads all the attributes of the given object immediate children and puts them in the resulting maps, one map for each child.
      Parameters:
      node - the node to read the attributes from
      Returns:
      the maps with all the attributes from the immediate children of the given node
      Throws:
      NullPointerException - if the given node is null
    • getAPI

      protected com.mooltiverse.oss.nyx.services.gitlab.API getAPI()
      Returns the internal API reference.
      Returns:
      the internal API reference.
    • getAttributes

      public Map<String,​Object> getAttributes()
      Returns the map of attributes this object is built on
      Returns:
      the map of attributes this object is built on