/** * Register a new consumer configured with Consumer Key. * * @param owner Identifier of the owner that registers the consumer (user ID or similar). * @param key Consumer key. * @param secret Consumer key secret. * @param attributes Additional attributes (name-values pairs - to store additional information * about the consumer, such as name, URI, description, etc.) * @return {@link Consumer} object for the newly registered consumer. */ public Consumer registerConsumer( final String owner, final String key, final String secret, final MultivaluedMap<String, String> attributes) { final Consumer c = new Consumer(key, secret, owner, attributes); consumerByConsumerKey.put(c.getKey(), c); return c; }