public Payment createWithTokenAndClient( String token, String clientId ) {
    ValidationUtils.validatesToken( token );
    ValidationUtils.validatesId( clientId );

    ParameterMap<String, String> params = new ParameterMap<String, String>();
    params.add( "token", token );
    params.add( "client", clientId );

    return RestfulUtils.create( PaymentService.PATH, params, Payment.class, super.httpClient );
  }
public Payment createWithTokenAndClient ( String token , String clientId ) { ValidationUtils . validatesToken ( token ) ; ValidationUtils . validatesId ( clientId ) ; ParameterMap < String , String > params = new ParameterMap < String , String > ( ) ; params . add ( "token" , token ) ; params . add ( "client" , clientId ) ; return RestfulUtils . create ( PaymentService . PATH , params , Payment . class , super . httpClient ) ; }
Creates a credit card or direct debit {@link Payment} from a given token. With the provided {@link Client}, the
{@link Payment} will be created and subsequently be added to the given {@link Client}.
@param token
Token generated by PAYMILL Bridge, which represents a credit card or direct debit.
@param clientId
The Id of a {@link Client}, which is already stored in PAYMILL.
@return New PAYMILL {@link Payment}.