<commit_before>spring-social-alfresco
======================

Maven

````xml
    <dependency>
      <groupId>org.springframework.social</groupId>
      <artifactId>spring-social-alfresco</artifactId>
      <version>0.2.4-RELEASE</version>
    </dependency>
````


How to use
````java
    AlfrescoConnectionFactory connectionFactory = new AlfrescoConnectionFactory(consumerKey, consumerSecret);
    
    OAuth2Parameters parameters = new OAuth2Parameters();
    parameters.setRedirectUri("http://localhost:8080/alfoauthsample/mycallback.html");  
    parameters.setScope(Alfresco.DEFAULT_SCOPE);
    parameters.setState("test");
    
    
    String authUrl = connectionFactory.getOAuthOperations().buildAuthenticateUrl(GrantType.AUTHORIZATION_CODE, parameters);
    
    //Do the dance here ...
    
    AccessGrant accessGrant = connectionFactory.getOAuthOperations().exchangeForAccess(accessToken, redirectUri, null);
    
    //Persist your tokens here ...
    
    Connection<Alfresco> connection = connectionFactory.createConnection(accessGrant);
    Alfresco alfresco = connection.getApi();
    <commit_msg>Update README with new version number for maven artifact<commit_after>spring-social-alfresco
======================

Maven

````xml
    <dependency>
      <groupId>org.springframework.social</groupId>
      <artifactId>spring-social-alfresco</artifactId>
      <version>0.2.5-RELEASE</version>
    </dependency>
````


How to use
````java
    AlfrescoConnectionFactory connectionFactory = new AlfrescoConnectionFactory(consumerKey, consumerSecret);
    
    OAuth2Parameters parameters = new OAuth2Parameters();
    parameters.setRedirectUri("http://localhost:8080/alfoauthsample/mycallback.html");  
    parameters.setScope(Alfresco.DEFAULT_SCOPE);
    parameters.setState("test");
    
    
    String authUrl = connectionFactory.getOAuthOperations().buildAuthenticateUrl(GrantType.AUTHORIZATION_CODE, parameters);
    
    //Do the dance here ...
    
    AccessGrant accessGrant = connectionFactory.getOAuthOperations().exchangeForAccess(accessToken, redirectUri, null);
    
    //Persist your tokens here ...
    
    Connection<Alfresco> connection = connectionFactory.createConnection(accessGrant);
    Alfresco alfresco = connection.getApi();
    
{'fraction_non_alphanumeric': 0.12428382547377699, 'fraction_numerical': 0.007933010136624064, 'mean_word_length': 4.2668213457076565, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 21, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3327778', 'n_tokens_mistral': 668, 'n_tokens_neox': 628, 'n_words': 102}