public final GitLabApi duplicate ( ) { Integer sudoUserId = this . getSudoAsId ( ) ; GitLabApi gitLabApi = new GitLabApi ( apiVersion , gitLabServerUrl , getTokenType ( ) , getAuthToken ( ) , getSecretToken ( ) , clientConfigProperties ) ; if ( sudoUserId != null ) { gitLabApi . apiClient . setSudoAsId ( sudoUserId ) ; } if ( getIgnoreCertificateErrors ( ) ) { gitLabApi . setIgnoreCertificateErrors ( true ) ; } gitLabApi . defaultPerPage = this . defaultPerPage ; return ( gitLabApi ) ; }
Create a new GitLabApi instance that is logically a duplicate of this instance with the exception off sudo state .