Skip to content

Commit a1ed8d9

Browse files
committed
first commit, sources
0 parents  commit a1ed8d9

12 files changed

+1417
-0
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
target

README.md

Whitespace-only changes.

pom.xml

+208
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,208 @@
1+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
2+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
3+
<modelVersion>4.0.0</modelVersion>
4+
<groupId>io.oauth</groupId>
5+
<artifactId>oauthio-java-client</artifactId>
6+
<packaging>jar</packaging>
7+
<name>oauthio-java-client</name>
8+
<version>1.0.0</version>
9+
<prerequisites>
10+
<maven>2.2.0</maven>
11+
</prerequisites>
12+
13+
<distributionManagement>
14+
<repository>
15+
<id>internal.repo</id>
16+
<name>Temporary Staging Repository</name>
17+
<url>file://${project.build.directory}/mvn-repo</url>
18+
</repository>
19+
</distributionManagement>
20+
21+
<build>
22+
<plugins>
23+
<plugin>
24+
<artifactId>maven-deploy-plugin</artifactId>
25+
<version>2.8.1</version>
26+
<configuration>
27+
<altDeploymentRepository>internal.repo::default::file://${project.build.directory}/mvn-repo</altDeploymentRepository>
28+
</configuration>
29+
</plugin>
30+
<plugin>
31+
<groupId>org.apache.maven.plugins</groupId>
32+
<artifactId>maven-surefire-plugin</artifactId>
33+
<version>2.12</version>
34+
<configuration>
35+
<systemProperties>
36+
<property>
37+
<name>loggerPath</name>
38+
<value>conf/log4j.properties</value>
39+
</property>
40+
</systemProperties>
41+
<argLine>-Xms512m -Xmx1500m</argLine>
42+
<parallel>methods</parallel>
43+
<forkMode>pertest</forkMode>
44+
</configuration>
45+
</plugin>
46+
<plugin>
47+
<groupId>com.github.github</groupId>
48+
<artifactId>site-maven-plugin</artifactId>
49+
<version>0.11</version>
50+
<configuration>
51+
<message>Maven artifacts for ${project.version}</message> <!-- git commit message -->
52+
<noJekyll>true</noJekyll> <!-- disable webpage processing -->
53+
<outputDirectory>${project.build.directory}/mvn-repo</outputDirectory> <!-- matches distribution management repository url above -->
54+
<branch>refs/heads/mvn-repo</branch> <!-- remote branch name -->
55+
<includes><include>**/*</include></includes>
56+
<repositoryName>sdk-java</repositoryName> <!-- github repo name -->
57+
<repositoryOwner>oauth-io</repositoryOwner> <!-- github username -->
58+
</configuration>
59+
<executions>
60+
<!-- run site-maven-plugin's 'site' target as part of the build's normal 'deploy' phase -->
61+
<execution>
62+
<goals>
63+
<goal>site</goal>
64+
</goals>
65+
<phase>deploy</phase>
66+
</execution>
67+
</executions>
68+
</plugin>
69+
<plugin>
70+
<artifactId>maven-dependency-plugin</artifactId>
71+
<executions>
72+
<execution>
73+
<phase>package</phase>
74+
<goals>
75+
<goal>copy-dependencies</goal>
76+
</goals>
77+
<configuration>
78+
<outputDirectory>${project.build.directory}/lib</outputDirectory>
79+
</configuration>
80+
</execution>
81+
</executions>
82+
</plugin>
83+
84+
<!-- attach test jar -->
85+
<plugin>
86+
<groupId>org.apache.maven.plugins</groupId>
87+
<artifactId>maven-jar-plugin</artifactId>
88+
<version>2.2</version>
89+
<executions>
90+
<execution>
91+
<goals>
92+
<goal>jar</goal>
93+
<goal>test-jar</goal>
94+
</goals>
95+
</execution>
96+
</executions>
97+
<configuration>
98+
</configuration>
99+
</plugin>
100+
101+
<plugin>
102+
<groupId>org.codehaus.mojo</groupId>
103+
<artifactId>build-helper-maven-plugin</artifactId>
104+
<version>1.9.1</version>
105+
<executions>
106+
<execution>
107+
<id>add_sources</id>
108+
<phase>generate-sources</phase>
109+
<goals>
110+
<goal>add-source</goal>
111+
</goals>
112+
<configuration>
113+
<sources>
114+
<source>src/main/java</source>
115+
</sources>
116+
</configuration>
117+
</execution>
118+
<execution>
119+
<id>add_test_sources</id>
120+
<phase>generate-test-sources</phase>
121+
<goals>
122+
<goal>add-test-source</goal>
123+
</goals>
124+
<configuration>
125+
<sources>
126+
<source>src/test/java</source>
127+
</sources>
128+
</configuration>
129+
</execution>
130+
</executions>
131+
</plugin>
132+
<plugin>
133+
<groupId>org.apache.maven.plugins</groupId>
134+
<artifactId>maven-compiler-plugin</artifactId>
135+
<version>2.3.2</version>
136+
<configuration>
137+
<source>1.6</source>
138+
<target>1.6</target>
139+
</configuration>
140+
</plugin>
141+
</plugins>
142+
</build>
143+
<dependencies>
144+
<dependency>
145+
<groupId>com.wordnik</groupId>
146+
<artifactId>swagger-annotations</artifactId>
147+
<version>${swagger-annotations-version}</version>
148+
</dependency>
149+
<dependency>
150+
<groupId>com.sun.jersey</groupId>
151+
<artifactId>jersey-client</artifactId>
152+
<version>${jersey-version}</version>
153+
</dependency>
154+
<dependency>
155+
<groupId>com.sun.jersey.contribs</groupId>
156+
<artifactId>jersey-multipart</artifactId>
157+
<version>${jersey-version}</version>
158+
</dependency>
159+
<dependency>
160+
<groupId>com.fasterxml.jackson.core</groupId>
161+
<artifactId>jackson-core</artifactId>
162+
<version>${jackson-version}</version>
163+
</dependency>
164+
<dependency>
165+
<groupId>com.fasterxml.jackson.core</groupId>
166+
<artifactId>jackson-annotations</artifactId>
167+
<version>${jackson-version}</version>
168+
</dependency>
169+
<dependency>
170+
<groupId>com.fasterxml.jackson.core</groupId>
171+
<artifactId>jackson-databind</artifactId>
172+
<version>${jackson-version}</version>
173+
</dependency>
174+
<dependency>
175+
<groupId>com.fasterxml.jackson.datatype</groupId>
176+
<artifactId>jackson-datatype-joda</artifactId>
177+
<version>2.1.5</version>
178+
</dependency>
179+
<dependency>
180+
<groupId>com.fasterxml.jackson.dataformat</groupId>
181+
<artifactId>jackson-dataformat-yaml</artifactId>
182+
<version>2.3.4</version>
183+
</dependency>
184+
<dependency>
185+
<groupId>joda-time</groupId>
186+
<artifactId>joda-time</artifactId>
187+
<version>${jodatime-version}</version>
188+
</dependency>
189+
190+
<!-- test dependencies -->
191+
<dependency>
192+
<groupId>junit</groupId>
193+
<artifactId>junit</artifactId>
194+
<version>${junit-version}</version>
195+
<scope>test</scope>
196+
</dependency>
197+
</dependencies>
198+
<properties>
199+
<swagger-annotations-version>1.5.3-M1</swagger-annotations-version>
200+
<jersey-version>1.18</jersey-version>
201+
<jackson-version>2.4.2</jackson-version>
202+
<jodatime-version>2.3</jodatime-version>
203+
<maven-plugin-version>1.0.0</maven-plugin-version>
204+
<junit-version>4.8.1</junit-version>
205+
<!-- github server corresponds to entry in ~/.m2/settings.xml -->
206+
<github.global.server>github</github.global.server>
207+
</properties>
208+
</project>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
package io.oauth.server;
2+
3+
public class ApiException extends Exception {
4+
int code = 0;
5+
String message = null;
6+
7+
public ApiException() {}
8+
9+
public ApiException(int code, String message) {
10+
this.code = code;
11+
this.message = message;
12+
}
13+
14+
public int getCode() {
15+
return code;
16+
}
17+
18+
public void setCode(int code) {
19+
this.code = code;
20+
}
21+
22+
public String getMessage() {
23+
return message;
24+
}
25+
26+
public void setMessage(String message) {
27+
this.message = message;
28+
}
29+
}

0 commit comments

Comments
 (0)