Class OAuthWebResponses


  • public abstract class OAuthWebResponses
    extends java.lang.Object
    Factory class to generate some common OAuthWebResponses. It uses html sites residing in the ressource folder, but provides plain text fallbacks if a specific site cannot be read.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String RESOURCE_DIR  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static org.syncany.plugins.transfer.oauth.OAuthWebResponse createBadResponse()
      This OAuthWebResponse is used when there was an error during the OAuth process.
      static org.syncany.plugins.transfer.oauth.OAuthWebResponse createValidResponse()
      This OAuthWebResponse is used when a token was succesfully extracted.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • createValidResponse

        public static org.syncany.plugins.transfer.oauth.OAuthWebResponse createValidResponse()
        This OAuthWebResponse is used when a token was succesfully extracted. It uses ValidWebResponse.html which should be placed in "/org/syncany/plugins/oauth/".
        Returns:
        Either the parsed html file or a fallback string.
      • createBadResponse

        public static org.syncany.plugins.transfer.oauth.OAuthWebResponse createBadResponse()
        This OAuthWebResponse is used when there was an error during the OAuth process. It uses BadRequestWebResponse.html which should be placed in "/org/syncany/plugins/oauth/".
        Returns:
        Either the parsed html file or a fallback string.