Skip to content

Commit 9f9dc87

Browse files
Doha2012Eugen
authored andcommitted
cleanup generated files (eugenp#1705)
* upgrade to spring boot 1.5.2 * add full update to REST API * modify ratings controller * upgrade herold * fix integration test * fix integration test * minor fix * fix integration test * fix integration test * minor cleanup * minor cleanup * remove log4j properties * use standard logbook.xml * remove log4j dependencies * remove commons-logging * merge * fix conflict * exclude commons-logging dependency * cleanup * minor fix * minor fix * fix dependency issues * Revert "fix dependency issues" This reverts commit 83bf1f9. * fix dependency issues * minor fix * minor fix * minor fix * cleanup generated files
1 parent f88d404 commit 9f9dc87

File tree

13 files changed

+359
-23
lines changed

13 files changed

+359
-23
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,5 @@ spring-openid/src/main/resources/application.properties
3131
.recommenders/
3232
/spring-hibernate4/nbproject/
3333
spring-security-openid/src/main/resources/application.properties
34+
35+
spring-all/*.log

apache-cxf/cxf-aegis/src/test/java/com/baeldung/cxf/aegis/BaeldungTest.java

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,10 @@
33
import static org.junit.Assert.assertEquals;
44
import static org.junit.Assert.assertNull;
55

6+
import org.junit.After;
67
import org.junit.Test;
78

9+
import java.io.File;
810
import java.io.FileInputStream;
911
import java.io.FileOutputStream;
1012
import java.lang.reflect.Type;
@@ -90,4 +92,12 @@ private CourseRepo unmarshalCourseRepo() throws Exception {
9092
xmlReader.close();
9193
return courseRepo;
9294
}
95+
96+
@After
97+
public void cleanup(){
98+
File testFile = new File(fileName);
99+
if (testFile.exists()) {
100+
testFile.delete();
101+
}
102+
}
93103
}

apache-poi/src/test/java/com/baeldung/jexcel/JExcelTest.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919

2020
import org.junit.Test;
2121
import org.junit.Before;
22+
import org.junit.After;
2223

2324
public class JExcelTest {
2425

@@ -53,4 +54,11 @@ public void whenParsingJExcelFile_thenCorrect() throws IOException, BiffExceptio
5354
.get(1));
5455
}
5556

57+
@After
58+
public void cleanup(){
59+
File testFile = new File(fileLocation);
60+
if (testFile.exists()) {
61+
testFile.delete();
62+
}
63+
}
5664
}

apache-poi/src/test/java/com/baeldung/poi/excel/ExcelTest.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616

1717
import org.junit.Test;
1818
import org.junit.Before;
19+
import org.junit.After;
1920

2021
public class ExcelTest {
2122

@@ -50,4 +51,11 @@ public void whenParsingPOIExcelFile_thenCorrect() throws IOException {
5051
.get(1));
5152
}
5253

54+
@After
55+
public void cleanup(){
56+
File testFile = new File(fileLocation);
57+
if (testFile.exists()) {
58+
testFile.delete();
59+
}
60+
}
5361
}

apache-poi/temp.xls

-13.5 KB
Binary file not shown.

apache-poi/temp.xlsx

-3.41 KB
Binary file not shown.

jaxb/pom.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,9 @@
135135
</sources>
136136
<outputDirectory>${basedir}/src/main/java</outputDirectory>
137137
<clearOutputDir>false</clearOutputDir>
138+
<noGeneratedHeaderComments>true</noGeneratedHeaderComments>
139+
<extension>true</extension>
140+
<generateEpisode>false</generateEpisode>
138141
</configuration>
139142
</plugin>
140143

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
2+
package com.baeldung.jaxb.gen;
3+
4+
import javax.xml.bind.annotation.XmlRegistry;
5+
6+
7+
/**
8+
* This object contains factory methods for each
9+
* Java content interface and Java element interface
10+
* generated in the com.baeldung.jaxb.gen package.
11+
* <p>An ObjectFactory allows you to programatically
12+
* construct new instances of the Java representation
13+
* for XML content. The Java representation of XML
14+
* content can consist of schema derived interfaces
15+
* and classes representing the binding of schema
16+
* type definitions, element declarations and model
17+
* groups. Factory methods for each of these are
18+
* provided in this class.
19+
*
20+
*/
21+
@XmlRegistry
22+
public class ObjectFactory {
23+
24+
25+
/**
26+
* Create a new ObjectFactory that can be used to create new instances of schema derived classes for package: com.baeldung.jaxb.gen
27+
*
28+
*/
29+
public ObjectFactory() {
30+
}
31+
32+
/**
33+
* Create an instance of {@link UserRequest }
34+
*
35+
*/
36+
public UserRequest createUserRequest() {
37+
return new UserRequest();
38+
}
39+
40+
/**
41+
* Create an instance of {@link UserResponse }
42+
*
43+
*/
44+
public UserResponse createUserResponse() {
45+
return new UserResponse();
46+
}
47+
48+
}
Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
2+
package com.baeldung.jaxb.gen;
3+
4+
import java.io.Serializable;
5+
import javax.xml.bind.annotation.XmlAccessType;
6+
import javax.xml.bind.annotation.XmlAccessorType;
7+
import javax.xml.bind.annotation.XmlElement;
8+
import javax.xml.bind.annotation.XmlRootElement;
9+
import javax.xml.bind.annotation.XmlType;
10+
11+
12+
/**
13+
* <p>Java class for UserRequest complex type.
14+
*
15+
* <p>The following schema fragment specifies the expected content contained within this class.
16+
*
17+
* <pre>
18+
* &lt;complexType name="UserRequest"&gt;
19+
* &lt;complexContent&gt;
20+
* &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&gt;
21+
* &lt;sequence&gt;
22+
* &lt;element name="id" type="{http://www.w3.org/2001/XMLSchema}int"/&gt;
23+
* &lt;element name="name" type="{http://www.w3.org/2001/XMLSchema}string"/&gt;
24+
* &lt;/sequence&gt;
25+
* &lt;/restriction&gt;
26+
* &lt;/complexContent&gt;
27+
* &lt;/complexType&gt;
28+
* </pre>
29+
*
30+
*
31+
*/
32+
@XmlAccessorType(XmlAccessType.FIELD)
33+
@XmlType(name = "UserRequest", propOrder = {
34+
"id",
35+
"name"
36+
})
37+
@XmlRootElement(name = "userRequest")
38+
public class UserRequest
39+
implements Serializable
40+
{
41+
42+
private final static long serialVersionUID = -1L;
43+
protected int id;
44+
@XmlElement(required = true)
45+
protected String name;
46+
47+
/**
48+
* Gets the value of the id property.
49+
*
50+
*/
51+
public int getId() {
52+
return id;
53+
}
54+
55+
/**
56+
* Sets the value of the id property.
57+
*
58+
*/
59+
public void setId(int value) {
60+
this.id = value;
61+
}
62+
63+
/**
64+
* Gets the value of the name property.
65+
*
66+
* @return
67+
* possible object is
68+
* {@link String }
69+
*
70+
*/
71+
public String getName() {
72+
return name;
73+
}
74+
75+
/**
76+
* Sets the value of the name property.
77+
*
78+
* @param value
79+
* allowed object is
80+
* {@link String }
81+
*
82+
*/
83+
public void setName(String value) {
84+
this.name = value;
85+
}
86+
87+
}
Lines changed: 149 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,149 @@
1+
2+
package com.baeldung.jaxb.gen;
3+
4+
import java.io.Serializable;
5+
import java.util.Calendar;
6+
import javax.xml.bind.annotation.XmlAccessType;
7+
import javax.xml.bind.annotation.XmlAccessorType;
8+
import javax.xml.bind.annotation.XmlElement;
9+
import javax.xml.bind.annotation.XmlRootElement;
10+
import javax.xml.bind.annotation.XmlSchemaType;
11+
import javax.xml.bind.annotation.XmlType;
12+
import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
13+
import org.w3._2001.xmlschema.Adapter1;
14+
15+
16+
/**
17+
* <p>Java class for UserResponse complex type.
18+
*
19+
* <p>The following schema fragment specifies the expected content contained within this class.
20+
*
21+
* <pre>
22+
* &lt;complexType name="UserResponse"&gt;
23+
* &lt;complexContent&gt;
24+
* &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&gt;
25+
* &lt;sequence&gt;
26+
* &lt;element name="id" type="{http://www.w3.org/2001/XMLSchema}int"/&gt;
27+
* &lt;element name="name" type="{http://www.w3.org/2001/XMLSchema}string"/&gt;
28+
* &lt;element name="gender" type="{http://www.w3.org/2001/XMLSchema}string"/&gt;
29+
* &lt;element name="created" type="{http://www.w3.org/2001/XMLSchema}dateTime"/&gt;
30+
* &lt;/sequence&gt;
31+
* &lt;/restriction&gt;
32+
* &lt;/complexContent&gt;
33+
* &lt;/complexType&gt;
34+
* </pre>
35+
*
36+
*
37+
*/
38+
@XmlAccessorType(XmlAccessType.FIELD)
39+
@XmlType(name = "UserResponse", propOrder = {
40+
"id",
41+
"name",
42+
"gender",
43+
"created"
44+
})
45+
@XmlRootElement(name = "userResponse")
46+
public class UserResponse
47+
implements Serializable
48+
{
49+
50+
private final static long serialVersionUID = -1L;
51+
protected int id;
52+
@XmlElement(required = true)
53+
protected String name;
54+
@XmlElement(required = true)
55+
protected String gender;
56+
@XmlElement(required = true, type = String.class)
57+
@XmlJavaTypeAdapter(Adapter1 .class)
58+
@XmlSchemaType(name = "dateTime")
59+
protected Calendar created;
60+
61+
/**
62+
* Gets the value of the id property.
63+
*
64+
*/
65+
public int getId() {
66+
return id;
67+
}
68+
69+
/**
70+
* Sets the value of the id property.
71+
*
72+
*/
73+
public void setId(int value) {
74+
this.id = value;
75+
}
76+
77+
/**
78+
* Gets the value of the name property.
79+
*
80+
* @return
81+
* possible object is
82+
* {@link String }
83+
*
84+
*/
85+
public String getName() {
86+
return name;
87+
}
88+
89+
/**
90+
* Sets the value of the name property.
91+
*
92+
* @param value
93+
* allowed object is
94+
* {@link String }
95+
*
96+
*/
97+
public void setName(String value) {
98+
this.name = value;
99+
}
100+
101+
/**
102+
* Gets the value of the gender property.
103+
*
104+
* @return
105+
* possible object is
106+
* {@link String }
107+
*
108+
*/
109+
public String getGender() {
110+
return gender;
111+
}
112+
113+
/**
114+
* Sets the value of the gender property.
115+
*
116+
* @param value
117+
* allowed object is
118+
* {@link String }
119+
*
120+
*/
121+
public void setGender(String value) {
122+
this.gender = value;
123+
}
124+
125+
/**
126+
* Gets the value of the created property.
127+
*
128+
* @return
129+
* possible object is
130+
* {@link String }
131+
*
132+
*/
133+
public Calendar getCreated() {
134+
return created;
135+
}
136+
137+
/**
138+
* Sets the value of the created property.
139+
*
140+
* @param value
141+
* allowed object is
142+
* {@link String }
143+
*
144+
*/
145+
public void setCreated(Calendar value) {
146+
this.created = value;
147+
}
148+
149+
}

0 commit comments

Comments
 (0)