@@ -0,0 +1,2368 @@
+/*%0A * Copyright 2014 Hiroki Uchida%0A *%0A * Licensed under the Apache License, Version 2.0 (the %22License%22);%0A * you may not use this file except in compliance with the License.%0A * You may obtain a copy of the License at%0A *%0A *      http://www.apache.org/licenses/LICENSE-2.0%0A *%0A * Unless required by applicable law or agreed to in writing, software%0A * distributed under the License is distributed on an %22AS IS%22 BASIS,%0A * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.%0A * See the License for the specific language governing permissions and%0A * limitations under the License.%0A */%0A%0Apackage com.nikuyoshi.oauth;%0A%0Aimport java.io.Serializable;%0A%0Apublic abstract class OAuthToken implements Serializable %7B%0A%0A  private static final long serialVersionUID = -918432242378692901L;%0A%0A    private final String token;%0A    private final String tokenSecret;%0A%0A    private String%5B%5D responseStr = null;%0A%0A    public OAuthToken(String token, String tokenSecret) %7B%0A        if(token == null)%0A            throw new IllegalArgumentException(%22Token can't be null%22);%0A        if(tokenSecret == null)%0A            throw new IllegalArgumentException(%22TokenSecret can't be null%22);            %0A        this.token = token;%0A        this.tokenSecret = tokenSecret;%0A    %7D%0A%0A    OAuthToken(String string) %7B%0A        responseStr = string.split(%22&%22);%0A        tokenSecret = getParameter(%22oauth_token_secret%22);%0A        token = getParameter(%22oauth_token%22);%0A    %7D%0A%0A    public String getToken() %7B%0A        return token;%0A    %7D%0A%0A    public String getTokenSecret() %7B%0A        return tokenSecret;%0A    %7D%0A%0A%0A    public String getParameter(String parameter) %7B%0A        String value = null;%0A        for (String str : responseStr) %7B%0A            if (str.startsWith(parameter + '=')) %7B%0A                value = str.split(%22=%22)%5B1%5D.trim();%0A                break;%0A            %7D%0A        %7D%0A        return value;%0A    %7D%0A%0A    @Override%0A    public boolean equals(Object o) %7B%0A        if (this == o) return true;%0A        if (!(o instanceof OAuthToken)) return false;%0A%0A        OAuthToken that = (OAuthToken) o;%0A%0A        if (!token.equals(that.token)) return false;%0A        if (!tokenSecret.equals(that.tokenSecret)) return false;%0A%0A        return true;%0A    %7D%0A%0A    @Override%0A    public int hashCode() %7B%0A        int result = token.hashCode();%0A        result = 31 * result + tokenSecret.hashCode();%0A        return result;%0A    %7D%0A%0A%7D%0A

Add OAuthToken class