Package org.brickred.socialauth

Examples of org.brickred.socialauth.SocialAuthConfig.load()


    SocialAuthConfig config = SocialAuthConfig.getDefault();
    InputStream in = null;
    try {
      in = DefaultSASFSocialAuthManager.class.getClassLoader()
          .getResourceAsStream(props.getOauthPropertiesFileString());
      config.load(in);
      this.socialAuthConfig = config;
    } catch (Exception e) {
      throw new SASFSecurityException(e);
    }
  }
View Full Code Here


    generateToken.getAccessToken();
  }

  private void getAccessToken() throws Exception {
    SocialAuthConfig config = SocialAuthConfig.getDefault();
    config.load();
    SocialAuthManager manager = new SocialAuthManager();
    manager.setSocialAuthConfig(config);

    URL aURL = new URL(successURL);
    host = aURL.getHost();
View Full Code Here

      }
    } else {
      InputStream in = SocialAuthenticationAction.class.getClassLoader()
          .getResourceAsStream("oauth_consumer.properties");
      SocialAuthConfig conf = SocialAuthConfig.getDefault();
      conf.load(in);
      manager = new SocialAuthManager();
      manager.setSocialAuthConfig(conf);
      userSession.put("socialAuthManager", manager);
    }
View Full Code Here

    SocialAuthConfig config = new SocialAuthConfig();
    File devConfig = Files.findFile("oauth_consumer.properties_dev"); //开发期所使用的配置文件
    if (devConfig == null)
      devConfig = Files.findFile("oauth_consumer.properties"); //真实环境所使用的配置文件
    if (devConfig == null)
      config.load(new NullInputStream());
    else
      config.load(new FileInputStream(devConfig));
    this.config = config;
  }
}
View Full Code Here

    if (devConfig == null)
      devConfig = Files.findFile("oauth_consumer.properties"); //真实环境所使用的配置文件
    if (devConfig == null)
      config.load(new NullInputStream());
    else
      config.load(new FileInputStream(devConfig));
    this.config = config;
  }
}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.