/** * twitterインスタンスを取得する */ public static Twitter getTwitterInstance(){ ConfigurationBuilder configurationbuilder = new ConfigurationBuilder(); configurationbuilder.setOAuthConsumerKey(Const.CONSUMER_KEY); configurationbuilder.setOAuthConsumerSecret(Const.CONSUMER_SECRET); Configuration configuration = configurationbuilder.build(); TwitterFactory factory = new TwitterFactory(configuration); AccessToken accessToken = new AccessToken(Const.CASHED_TOKEN, Const.CASHED_SECRET); return factory.getInstance(accessToken); }