Skip to content
This repository was archived by the owner on Nov 21, 2025. It is now read-only.

Commit cc67201

Browse files
committed
Merge pull request #3 from jpdiazvaz/master
Added Maven support and code cleanup
2 parents e8fb294 + 33f3f32 commit cc67201

11 files changed

Lines changed: 42 additions & 70 deletions

File tree

pom.xml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
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/xsd/maven-4.0.0.xsd">
3+
<modelVersion>4.0.0</modelVersion>
4+
5+
<groupId>com.mcplusa.google</groupId>
6+
<artifactId>mcplusa-google-feeder-java</artifactId>
7+
<version>1.0.0</version>
8+
<packaging>jar</packaging>
9+
10+
<name>mcplusa-google-feeder-java</name>
11+
<url>http://maven.apache.org</url>
12+
13+
<properties>
14+
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
15+
</properties>
16+
17+
<dependencies>
18+
<dependency>
19+
<groupId>junit</groupId>
20+
<artifactId>junit</artifactId>
21+
<version>3.8.1</version>
22+
<scope>test</scope>
23+
</dependency>
24+
<dependency>
25+
<groupId>log4j</groupId>
26+
<artifactId>log4j</artifactId>
27+
<version>1.2.17</version>
28+
</dependency>
29+
<dependency>
30+
<groupId>xerces</groupId>
31+
<artifactId>xercesImpl</artifactId>
32+
<version>2.8.0</version>
33+
</dependency>
34+
<dependency>
35+
<groupId>commons-httpclient</groupId>
36+
<artifactId>commons-httpclient</artifactId>
37+
<version>3.1</version>
38+
</dependency>
39+
</dependencies>
40+
</project>

src/com/mcplusa/google/feeder/FeederUtil.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
/*
2-
* To change this template, choose Tools | Templates
3-
* and open the template in the editor.
4-
*/
5-
61
package com.mcplusa.google.feeder;
72

83
import java.io.*;

src/com/mcplusa/google/feeder/GSAContentItem.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
/*
2-
* To change this template, choose Tools | Templates
3-
* and open the template in the editor.
4-
*/
5-
61
package com.mcplusa.google.feeder;
72

83
import java.util.*;

src/com/mcplusa/google/feeder/GSAFeed.java

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
/*
2-
* To change this template, choose Tools | Templates
3-
* and open the template in the editor.
4-
*/
51
package com.mcplusa.google.feeder;
62

73
import java.io.IOException;
@@ -99,13 +95,12 @@ public void BuildHeader() throws SAXException, IOException {
9995

10096
public final String WriteXMLToFile(String gsa) {
10197
logger.info("Starting WriteXmlToFile");
102-
String filename = "asdf" + "something";
10398
Date now = new Date();
10499
SimpleDateFormat sd = new SimpleDateFormat("yyyy_mm_dd_hh_ss");
105100

106101
String timestamp = sd.format(now);
107102

108-
filename = this.dataSource + "_" + timestamp + ".xml";
103+
String filename = this.dataSource + "_" + timestamp + ".xml";
109104
try {
110105
if (feederFolder.length() > 0) {
111106
if (feederFolder.endsWith("\\")) {

src/com/mcplusa/google/feeder/GSAMetaDataItem.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
/*
2-
* To change this template, choose Tools | Templates
3-
* and open the template in the editor.
4-
*/
5-
61
package com.mcplusa.google.feeder;
72

83
/**

src/com/mcplusa/google/feeder/constants/ConnectorConstants.java

Lines changed: 1 addition & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
/*
2-
* To change this template, choose Tools | Templates
3-
* and open the template in the editor.
4-
*/
5-
61
package com.mcplusa.google.feeder.constants;
72

83
/**
@@ -12,41 +7,26 @@
127
public class ConnectorConstants {
138
// mime
149
public final static String MIME_TYPE = "mimetype";
15-
1610
public final static String MIME_TEXT = "text/plain";
1711

1812
// feeder
1913
public final static String FEEDER_LAST_MODIFIED = "last-modified";
20-
2114
public final static String FEEDER_NAME = "name";
22-
2315
public final static String FEEDER_CONTENT = "content";
24-
2516
public final static String FEEDER_METADATA = "metadata";
26-
2717
public final static String FEEDER_META = "meta";
28-
2918
public final static String FEEDER_URL = "url";
30-
3119
public final static String FEEDER_HEADER = "header";
32-
3320
public final static String FEEDER_RECORD = "record";
34-
3521
public final static String FEEDER_GROUP = "group";
36-
3722
public final static String FEEDER_GSAFEED = "gsafeed";
38-
3923
public final static String FEEDER_TYPE = "feedtype";
40-
4124
public final static String FEEDER_DATA = "data";
42-
4325
public final static String FEEDER_DS = "datasource";
4426

4527
// feed types
4628
public final static String FEEDER_TYPE_FULL = "full";
47-
4829
public final static String FEEDER_TYPE_INC = "incremental";
49-
5030
public final static String FEEDER_TYPE_URL = "metadata-and-url";
5131

5232
// authentication
@@ -68,10 +48,7 @@ public class ConnectorConstants {
6848
public static String TAG_ID = "ID";
6949
public static String TAG_MODIFIED = "Modified";
7050
public static String TAG_URL = "ServerUrl";
71-
//
72-
public static String SP_NAMESPACE = "http://schemas.microsoft.com/sharepoint/soap/";
73-
public static String SP_PREFIX = "SOAPSDK9";
74-
public static String SiteDirectoryTag = "SiteDirectory";
51+
7552
// feeder
7653
public final static String FEEDER_GATE = ":19900/xmlfeed";
7754

src/com/mcplusa/google/feeder/constants/GSAAuthMethodTypes.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
/*
2-
* To change this template, choose Tools | Templates
3-
* and open the template in the editor.
4-
*/
5-
61
package com.mcplusa.google.feeder.constants;
72

83
/**

src/com/mcplusa/google/feeder/constants/GSAFeedType.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
/*
2-
* To change this template, choose Tools | Templates
3-
* and open the template in the editor.
4-
*/
5-
61
package com.mcplusa.google.feeder.constants;
72

83
/**

src/com/mcplusa/google/feeder/constants/GSAMimeTypes.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
/*
2-
* To change this template, choose Tools | Templates
3-
* and open the template in the editor.
4-
*/
5-
61
package com.mcplusa.google.feeder.constants;
72

83
/**

src/com/mcplusa/google/feeder/uploader/GSAUploader.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
/*
2-
* To change this template, choose Tools | Templates
3-
* and open the template in the editor.
4-
*/
5-
61
package com.mcplusa.google.feeder.uploader;
72

83
import com.mcplusa.google.feeder.constants.*;

0 commit comments

Comments
 (0)