1 /* 2 * Copyright 2008 Web Cohesion 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * https://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package org.springframework.security.oauth.provider.token; 18 19 import java.io.Serializable; 20 21 /** 22 * @author Ryan Heaton 23 */ 24 public interface OAuthProviderToken extends Serializable { 25 /** 26 * The value of the token. 27 * 28 * @return The value of the token. 29 */ 30 String getValue(); 31 32 /** 33 * The callback URL associated with this token. 34 * 35 * @return The callback URL associated with this token. 36 */ 37 String getCallbackUrl(); 38 39 /** 40 * The verifier string for this token. 41 * 42 * @return The verifier string for this token. 43 */ 44 String getVerifier(); 45 46 /** 47 * The token secret. 48 * 49 * @return The token secret. 50 */ 51 String getSecret(); 52 53 /** 54 * The consumer key associated with this oauth token. 55 * 56 * @return The consumer key associated with this oauth token. 57 */ 58 String getConsumerKey(); 59 60 /** 61 * Whether this is an OAuth access token. 62 * 63 * @return Whether this is an OAuth access token. 64 */ 65 boolean isAccessToken(); 66 }