src/main/java/com/simpligility/maven/plugins/android/common/AndroidPublisherHelper.java
public static AndroidPublisher init( String applicationName, String serviceAccountEmail, File pk12File )
            throws IOException, GeneralSecurityException
    {

        // Authorization.
        newTrustedTransport();
        Credential credential = authorizeWithServiceAccount( serviceAccountEmail, pk12File );

        // Set up and return API client.
        return new AndroidPublisher.Builder( httpTransport, JSON_FACTORY, credential )
                .setApplicationName( applicationName )
                .build();
    }
public static AndroidPublisher init( String applicationName, String serviceAccountEmail, File pk12File )
            throws IOException, GeneralSecurityException
    {

        // Authorization.
        newTrustedTransport();
        Credential credential = authorizeWithServiceAccount( serviceAccountEmail, pk12File );

        // Set up and return API client.
        return new AndroidPublisher.Builder( httpTransport, JSON_FACTORY, credential )
                .setApplicationName( applicationName )
                .build();
    }
public static AndroidPublisher init ( String applicationName , String serviceAccountEmail , File pk12File ) throws IOException , GeneralSecurityException { // Authorization. newTrustedTransport ( ) ; Credential credential = authorizeWithServiceAccount ( serviceAccountEmail , pk12File ) ; // Set up and return API client. return new AndroidPublisher . Builder ( httpTransport , JSON_FACTORY , credential ) . setApplicationName ( applicationName ) . build ( ) ; }
Performs all necessary setup steps for running requests against the API.

@param serviceAccountEmail the Service Account Email (empty if using
installed application)
@return the {@Link AndroidPublisher} service
@throws GeneralSecurityException
@throws IOException
Performs all necessary setup steps for running requests against the API .