00064 Change package to org.monkeyk.sos

0.4-beta
Li Shengzhao 2015-11-16 22:09:12 +08:00
parent 2c1ded395a
commit a16e41c2c8
38 changed files with 89 additions and 93 deletions

View File

@ -4,7 +4,7 @@
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>wdcy.cc</groupId>
<groupId>monkeyk.com</groupId>
<artifactId>spring-oauth-server</artifactId>
<version>0.4-beta</version>
<name>spring-oauth-server</name>

View File

@ -1,7 +1,7 @@
package cc.wdcy.domain;
package com.monkeyk.sos.domain;
import cc.wdcy.infrastructure.DateUtils;
import cc.wdcy.domain.shared.GuidGenerator;
import com.monkeyk.sos.infrastructure.DateUtils;
import com.monkeyk.sos.domain.shared.GuidGenerator;
import java.io.Serializable;
import java.util.Date;

View File

@ -1,7 +1,7 @@
package cc.wdcy.domain.dto;
package com.monkeyk.sos.domain.dto;
import cc.wdcy.domain.oauth.OauthClientDetails;
import cc.wdcy.infrastructure.DateUtils;
import com.monkeyk.sos.domain.oauth.OauthClientDetails;
import com.monkeyk.sos.infrastructure.DateUtils;
import org.apache.commons.lang.StringUtils;
import java.io.Serializable;

View File

@ -1,7 +1,7 @@
package cc.wdcy.domain.dto;
package com.monkeyk.sos.domain.dto;
import cc.wdcy.domain.user.Privilege;
import cc.wdcy.domain.user.User;
import com.monkeyk.sos.domain.user.Privilege;
import com.monkeyk.sos.domain.user.User;
import java.io.Serializable;
import java.util.ArrayList;

View File

@ -1,4 +1,4 @@
package cc.wdcy.domain.oauth;
package com.monkeyk.sos.domain.oauth;
import org.springframework.security.oauth2.provider.client.JdbcClientDetailsService;

View File

@ -1,6 +1,6 @@
package cc.wdcy.domain.oauth;
package com.monkeyk.sos.domain.oauth;
import cc.wdcy.infrastructure.DateUtils;
import com.monkeyk.sos.infrastructure.DateUtils;
import java.io.Serializable;
import java.util.Date;

View File

@ -1,6 +1,6 @@
package cc.wdcy.domain.oauth;
package com.monkeyk.sos.domain.oauth;
import cc.wdcy.domain.shared.Repository;
import com.monkeyk.sos.domain.shared.Repository;
import java.util.List;

View File

@ -1,4 +1,4 @@
package cc.wdcy.domain.shared;
package com.monkeyk.sos.domain.shared;
import java.util.UUID;

View File

@ -1,4 +1,4 @@
package cc.wdcy.domain.shared;
package com.monkeyk.sos.domain.shared;
/**
* @author Shengzhao Li

View File

@ -1,7 +1,7 @@
package cc.wdcy.domain.shared.security;
package com.monkeyk.sos.domain.shared.security;
import cc.wdcy.domain.user.Privilege;
import cc.wdcy.domain.user.User;
import com.monkeyk.sos.domain.user.Privilege;
import com.monkeyk.sos.domain.user.User;
import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.authority.SimpleGrantedAuthority;
import org.springframework.security.core.userdetails.UserDetails;

View File

@ -1,4 +1,4 @@
package cc.wdcy.domain.user;
package com.monkeyk.sos.domain.user;
/**
* @author Shengzhao Li

View File

@ -1,8 +1,7 @@
package cc.wdcy.domain.user;
package com.monkeyk.sos.domain.user;
import cc.wdcy.domain.AbstractDomain;
import com.monkeyk.sos.domain.AbstractDomain;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

View File

@ -1,6 +1,6 @@
package cc.wdcy.domain.user;
package com.monkeyk.sos.domain.user;
import cc.wdcy.domain.shared.Repository;
import com.monkeyk.sos.domain.shared.Repository;
/**
* @author Shengzhao Li

View File

@ -1,4 +1,4 @@
package cc.wdcy.infrastructure;
package com.monkeyk.sos.infrastructure;
import java.text.SimpleDateFormat;
import java.util.Date;

View File

@ -9,9 +9,9 @@
* it only in accordance with the terms of the license agreement you
* entered into with MONKEYK Information Technology Co. Ltd.
*/
package cc.wdcy.infrastructure.jdbc;
package com.monkeyk.sos.infrastructure.jdbc;
import cc.wdcy.domain.oauth.OauthClientDetails;
import com.monkeyk.sos.domain.oauth.OauthClientDetails;
import org.springframework.jdbc.core.RowMapper;
import java.sql.ResultSet;

View File

@ -9,14 +9,12 @@
* it only in accordance with the terms of the license agreement you
* entered into with MONKEYK Information Technology Co. Ltd.
*/
package cc.wdcy.infrastructure.jdbc;
package com.monkeyk.sos.infrastructure.jdbc;
import cc.wdcy.domain.oauth.OauthClientDetails;
import cc.wdcy.domain.oauth.OauthRepository;
import com.monkeyk.sos.domain.oauth.OauthClientDetails;
import com.monkeyk.sos.domain.oauth.OauthRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.dao.DataAccessException;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.jdbc.core.PreparedStatementCallback;
import org.springframework.jdbc.core.PreparedStatementSetter;
import org.springframework.stereotype.Repository;

View File

@ -9,11 +9,11 @@
* it only in accordance with the terms of the license agreement you
* entered into with MONKEYK Information Technology Co. Ltd.
*/
package cc.wdcy.infrastructure.jdbc;
package com.monkeyk.sos.infrastructure.jdbc;
import cc.wdcy.domain.user.Privilege;
import cc.wdcy.domain.user.User;
import cc.wdcy.domain.user.UserRepository;
import com.monkeyk.sos.domain.user.Privilege;
import com.monkeyk.sos.domain.user.User;
import com.monkeyk.sos.domain.user.UserRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.jdbc.core.PreparedStatementSetter;

View File

@ -9,9 +9,9 @@
* it only in accordance with the terms of the license agreement you
* entered into with MONKEYK Information Technology Co. Ltd.
*/
package cc.wdcy.infrastructure.jdbc;
package com.monkeyk.sos.infrastructure.jdbc;
import cc.wdcy.domain.user.User;
import com.monkeyk.sos.domain.user.User;
import org.springframework.jdbc.core.RowMapper;
import java.sql.ResultSet;

View File

@ -1,7 +1,7 @@
package cc.wdcy.service;
package com.monkeyk.sos.service;
import cc.wdcy.domain.dto.OauthClientDetailsDto;
import cc.wdcy.domain.oauth.OauthClientDetails;
import com.monkeyk.sos.domain.dto.OauthClientDetailsDto;
import com.monkeyk.sos.domain.oauth.OauthClientDetails;
import java.util.List;

View File

@ -1,6 +1,6 @@
package cc.wdcy.service;
package com.monkeyk.sos.service;
import cc.wdcy.domain.dto.UserJsonDto;
import com.monkeyk.sos.domain.dto.UserJsonDto;
import org.springframework.security.core.userdetails.UserDetailsService;
/**

View File

@ -1,9 +1,9 @@
package cc.wdcy.service.impl;
package com.monkeyk.sos.service.impl;
import cc.wdcy.domain.dto.OauthClientDetailsDto;
import cc.wdcy.domain.oauth.OauthClientDetails;
import cc.wdcy.domain.oauth.OauthRepository;
import cc.wdcy.service.OauthService;
import com.monkeyk.sos.domain.dto.OauthClientDetailsDto;
import com.monkeyk.sos.domain.oauth.OauthClientDetails;
import com.monkeyk.sos.domain.oauth.OauthRepository;
import com.monkeyk.sos.service.OauthService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

View File

@ -1,10 +1,10 @@
package cc.wdcy.service.impl;
package com.monkeyk.sos.service.impl;
import cc.wdcy.domain.dto.UserJsonDto;
import cc.wdcy.domain.shared.security.WdcyUserDetails;
import cc.wdcy.domain.user.User;
import cc.wdcy.domain.user.UserRepository;
import cc.wdcy.service.UserService;
import com.monkeyk.sos.domain.dto.UserJsonDto;
import com.monkeyk.sos.domain.shared.security.WdcyUserDetails;
import com.monkeyk.sos.domain.user.User;
import com.monkeyk.sos.domain.user.UserRepository;
import com.monkeyk.sos.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.core.Authentication;
import org.springframework.security.core.GrantedAuthority;

View File

@ -1,4 +1,4 @@
package cc.wdcy.web;
package com.monkeyk.sos.web;
import org.apache.commons.lang.StringUtils;

View File

@ -1,8 +1,8 @@
package cc.wdcy.web.controller;
package com.monkeyk.sos.web.controller;
import cc.wdcy.domain.dto.OauthClientDetailsDto;
import cc.wdcy.service.OauthService;
import cc.wdcy.web.oauth.OauthClientDetailsDtoValidator;
import com.monkeyk.sos.domain.dto.OauthClientDetailsDto;
import com.monkeyk.sos.service.OauthService;
import com.monkeyk.sos.web.oauth.OauthClientDetailsDtoValidator;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;

View File

@ -1,4 +1,4 @@
package cc.wdcy.web.controller;
package com.monkeyk.sos.web.controller;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

View File

@ -1,7 +1,7 @@
package cc.wdcy.web.controller.mobile;
package com.monkeyk.sos.web.controller.mobile;
import cc.wdcy.domain.dto.UserJsonDto;
import cc.wdcy.service.UserService;
import com.monkeyk.sos.domain.dto.UserJsonDto;
import com.monkeyk.sos.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

View File

@ -1,7 +1,7 @@
package cc.wdcy.web.controller.unity;
package com.monkeyk.sos.web.controller.unity;
import cc.wdcy.domain.dto.UserJsonDto;
import cc.wdcy.service.UserService;
import com.monkeyk.sos.domain.dto.UserJsonDto;
import com.monkeyk.sos.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

View File

@ -1,7 +1,7 @@
package cc.wdcy.web.oauth;
package com.monkeyk.sos.web.oauth;
import cc.wdcy.domain.dto.OauthClientDetailsDto;
import cc.wdcy.service.OauthService;
import com.monkeyk.sos.domain.dto.OauthClientDetailsDto;
import com.monkeyk.sos.service.OauthService;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

View File

@ -1,7 +1,7 @@
package cc.wdcy.web.oauth;
package com.monkeyk.sos.web.oauth;
import cc.wdcy.domain.oauth.OauthClientDetails;
import cc.wdcy.service.OauthService;
import com.monkeyk.sos.domain.oauth.OauthClientDetails;
import com.monkeyk.sos.service.OauthService;
import org.springframework.security.core.Authentication;
import org.springframework.security.oauth2.provider.AuthorizationRequest;
import org.springframework.security.oauth2.provider.approval.TokenStoreUserApprovalHandler;

View File

@ -10,7 +10,7 @@
<!--annotation configuration -->
<context:annotation-config/>
<context:component-scan base-package="cc.wdcy"/>
<context:component-scan base-package="com.monkeyk.sos"/>
<!-- property configuration -->
<bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">

View File

@ -83,7 +83,7 @@
<!--</oauth2:client-details-service>-->
<beans:bean id="clientDetailsService" class="cc.wdcy.domain.oauth.CustomJdbcClientDetailsService">
<beans:bean id="clientDetailsService" class="com.monkeyk.sos.domain.oauth.CustomJdbcClientDetailsService">
<beans:constructor-arg index="0" ref="dataSource"/>
</beans:bean>
@ -113,7 +113,7 @@
</beans:bean>
<beans:bean id="oauthUserApprovalHandler" class="cc.wdcy.web.oauth.OauthUserApprovalHandler">
<beans:bean id="oauthUserApprovalHandler" class="com.monkeyk.sos.web.oauth.OauthUserApprovalHandler">
<beans:property name="tokenStore" ref="tokenStore"/>
<beans:property name="clientDetailsService" ref="clientDetailsService"/>
<beans:property name="requestFactory" ref="oAuth2RequestFactory"/>

View File

@ -7,7 +7,7 @@
<!--aop-->
<aop:config>
<aop:advisor advice-ref="applicationAdvisor" pointcut="execution(* cc.wdcy.service.*.*(..))"/>
<aop:advisor advice-ref="applicationAdvisor" pointcut="execution(* com.monkeyk.sos.service.*.*(..))"/>
</aop:config>
<!--advisor-->

View File

@ -12,7 +12,7 @@
<!--annotation configuration -->
<context:annotation-config/>
<context:component-scan base-package="cc.wdcy.web"/>
<context:component-scan base-package="com.monkeyk.sos.web"/>
<!--static resource-->
<mvc:resources mapping="/index.jsp*" location="/index.jsp"/>

View File

@ -1,4 +1,4 @@
package cc.wdcy;
package com.monkeyk.sos;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.testng.AbstractTransactionalTestNGSpringContextTests;

View File

@ -1,4 +1,4 @@
package cc.wdcy;
package com.monkeyk.sos;
import org.springframework.beans.factory.config.PropertyPlaceholderConfigurer;
import org.springframework.context.ApplicationContextInitializer;

View File

@ -1,6 +1,6 @@
package cc.wdcy.infrastructure;
package com.monkeyk.sos.infrastructure;
import cc.wdcy.ContextTest;
import com.monkeyk.sos.ContextTest;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jdbc.core.JdbcTemplate;

View File

@ -9,12 +9,12 @@
* it only in accordance with the terms of the license agreement you
* entered into with MONKEYK Information Technology Co. Ltd.
*/
package cc.wdcy.infrastructure.jdbc;
package com.monkeyk.sos.infrastructure.jdbc;
import cc.wdcy.domain.oauth.OauthClientDetails;
import cc.wdcy.domain.oauth.OauthRepository;
import cc.wdcy.domain.shared.GuidGenerator;
import cc.wdcy.infrastructure.AbstractRepositoryTest;
import com.monkeyk.sos.domain.oauth.OauthClientDetails;
import com.monkeyk.sos.domain.oauth.OauthRepository;
import com.monkeyk.sos.domain.shared.GuidGenerator;
import com.monkeyk.sos.infrastructure.AbstractRepositoryTest;
import org.springframework.beans.factory.annotation.Autowired;
import org.testng.annotations.Test;

View File

@ -9,15 +9,14 @@
* it only in accordance with the terms of the license agreement you
* entered into with MONKEYK Information Technology Co. Ltd.
*/
package cc.wdcy.infrastructure.jdbc;
package com.monkeyk.sos.infrastructure.jdbc;
import cc.wdcy.domain.user.User;
import cc.wdcy.domain.user.UserRepository;
import cc.wdcy.infrastructure.AbstractRepositoryTest;
import com.monkeyk.sos.domain.user.User;
import com.monkeyk.sos.domain.user.UserRepository;
import com.monkeyk.sos.infrastructure.AbstractRepositoryTest;
import org.springframework.beans.factory.annotation.Autowired;
import org.testng.annotations.Test;
import static org.testng.Assert.*;
import static org.testng.AssertJUnit.assertEquals;
import static org.testng.AssertJUnit.assertNotNull;
import static org.testng.AssertJUnit.assertNull;