Skip to content

Commit 4df69f1

Browse files
committedJan 23, 2025·
Relocate API Types to Separate Module
1 parent 48ffe47 commit 4df69f1

40 files changed

+176
-83
lines changed
 

‎pom.xml

+1
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@
5555

5656
<modules>
5757
<module>vcell-admin</module>
58+
<module>vcell-api-types</module>
5859
<module>vcell-api</module>
5960
<module>vcell-apiclient</module>
6061
<module>vcell-client</module>

‎vcell-api-types/pom.xml

+87
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 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+
<parent>
6+
<groupId>org.vcell</groupId>
7+
<artifactId>vcell-pom</artifactId>
8+
<version>0.0.1-SNAPSHOT</version>
9+
</parent>
10+
11+
<artifactId>vcell-api-types</artifactId>
12+
13+
<name>vcell-api-types</name>
14+
15+
<description>Types used for communication.</description>
16+
<version>1.0.0</version>
17+
<url>https://maven.apache.org</url>
18+
<inceptionYear>2025</inceptionYear>
19+
<organization>
20+
<name>VCell</name>
21+
<url>https://vcell.org</url>
22+
</organization>
23+
<licenses>
24+
<license>
25+
<name>MIT</name>
26+
<url>https://opensource.org/licenses/MIT</url>
27+
</license>
28+
</licenses>
29+
30+
<developers>
31+
<developer>
32+
<id>avocadomoon</id>
33+
<name>Ezequiel Valencia</name>
34+
<roles>
35+
<role>founder</role>
36+
<role>lead</role>
37+
<role>developer</role>
38+
<role>debugger</role>
39+
<role>reviewer</role>
40+
<role>support</role>
41+
<role>maintainer</role>
42+
</roles>
43+
</developer>
44+
</developers>
45+
46+
<mailingLists>
47+
<mailingList>
48+
<name>VCell Open Discussion Forum</name>
49+
<subscribe>https://groups.google.com/group/vcell-discuss</subscribe>
50+
<unsubscribe>https://groups.google.com/group/vcell-discuss</unsubscribe>
51+
<post>vcell-discuss@googlegroups.com</post>
52+
<archive>https://groups.google.com/group/vcell-discuss</archive>
53+
</mailingList>
54+
</mailingLists>
55+
56+
<scm>
57+
<connection>scm:git:git://github.com/virtualcell/vcell</connection>
58+
<developerConnection>scm:git:git@github.com:virtualcell/vcell</developerConnection>
59+
<tag>HEAD</tag>
60+
<url>https://github.com/virtualcell/vcell</url>
61+
</scm>
62+
<issueManagement>
63+
<system>Bugzilla</system>
64+
<url>https://github.com/virtualcell/vcell/issues</url>
65+
</issueManagement>
66+
67+
<properties>
68+
<license.licenseName>MIT</license.licenseName>
69+
<license.copyrightOwners>UConn Health</license.copyrightOwners>
70+
</properties>
71+
72+
<repositories>
73+
<repository>
74+
<id>maven-restlet</id>
75+
<name>Restlet repository</name>
76+
<url>https://maven.restlet.talend.com</url>
77+
</repository>
78+
</repositories>
79+
80+
<dependencies>
81+
<dependency>
82+
<groupId>org.vcell</groupId>
83+
<artifactId>vcell-core</artifactId>
84+
<version>0.0.1-SNAPSHOT</version>
85+
</dependency>
86+
</dependencies>
87+
</project>

‎vcell-core/src/main/java/cbit/rmi/event/client/common/AccessTokenRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/AccessTokenRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33

44

‎vcell-core/src/main/java/cbit/rmi/event/client/common/ApplicationRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/ApplicationRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33

44
public class ApplicationRepresentation {

‎vcell-core/src/main/java/cbit/rmi/event/client/common/BioModelLink.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/BioModelLink.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33
public class BioModelLink {
44
public final static String bmid = "bioModelKey";

‎vcell-core/src/main/java/cbit/rmi/event/client/common/BiomodelRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/BiomodelRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33

44
public class BiomodelRepresentation {

‎vcell-core/src/main/java/cbit/rmi/event/client/common/MathModelLink.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/MathModelLink.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33

44
public class MathModelLink {

‎vcell-core/src/main/java/cbit/rmi/event/client/common/SimDataRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/SimDataRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33

44

‎vcell-core/src/main/java/cbit/rmi/event/client/common/SimDataValuesRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/SimDataValuesRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33

44

‎vcell-core/src/main/java/cbit/rmi/event/client/common/SimDataVariableRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/SimDataVariableRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33

44

‎vcell-core/src/main/java/cbit/rmi/event/client/common/SimDataVariableValuesRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/SimDataVariableValuesRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33

44

‎vcell-core/src/main/java/cbit/rmi/event/client/common/SimpleJobStatusRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/SimpleJobStatusRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33
import java.util.Date;
44

‎vcell-core/src/main/java/cbit/rmi/event/client/common/SimulationRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/SimulationRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33

44

‎vcell-core/src/main/java/cbit/rmi/event/client/common/SimulationTaskRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/SimulationTaskRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.common;
1+
package org.vcell.api.types.common;
22

33

44
public class SimulationTaskRepresentation {

‎vcell-core/src/main/java/cbit/rmi/event/client/common/UserInfo.java ‎vcell-api-types/src/main/java/org/vcell/api/types/common/UserInfo.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* http://www.opensource.org/licenses/mit-license.php
99
*/
1010

11-
package cbit.rmi.event.client.common;
11+
package org.vcell.api.types.common;
1212

1313
import java.util.Date;
1414

‎vcell-core/src/main/java/cbit/rmi/event/client/events/BroadcastEventRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/events/BroadcastEventRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.events;
1+
package org.vcell.api.types.events;
22

33
public class BroadcastEventRepresentation {
44

‎vcell-core/src/main/java/cbit/rmi/event/client/events/DataJobEventRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/events/DataJobEventRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.events;
1+
package org.vcell.api.types.events;
22

33
public class DataJobEventRepresentation {
44

‎vcell-core/src/main/java/cbit/rmi/event/client/events/EventWrapper.java ‎vcell-api-types/src/main/java/org/vcell/api/types/events/EventWrapper.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.events;
1+
package org.vcell.api.types.events;
22

33
public class EventWrapper {
44

‎vcell-core/src/main/java/cbit/rmi/event/client/events/ExportEventRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/events/ExportEventRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.events;
1+
package org.vcell.api.types.events;
22

33
public class ExportEventRepresentation {
44

‎vcell-core/src/main/java/cbit/rmi/event/client/events/ExportHumanReadableDataSpec.java ‎vcell-api-types/src/main/java/org/vcell/api/types/events/ExportHumanReadableDataSpec.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.events;
1+
package org.vcell.api.types.events;
22

33
import java.util.ArrayList;
44
import java.util.HashMap;

‎vcell-core/src/main/java/cbit/rmi/event/client/events/ExportTimeSpecs.java ‎vcell-api-types/src/main/java/org/vcell/api/types/events/ExportTimeSpecs.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.events;
1+
package org.vcell.api.types.events;
22

33
public class ExportTimeSpecs {
44
public final int beginTimeIndex;

‎vcell-core/src/main/java/cbit/rmi/event/client/events/ExportVariableSpecs.java ‎vcell-api-types/src/main/java/org/vcell/api/types/events/ExportVariableSpecs.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.events;
1+
package org.vcell.api.types.events;
22

33
public class ExportVariableSpecs {
44
public final String[] variableNames;

‎vcell-core/src/main/java/cbit/rmi/event/client/events/SimulationJobStatusEventRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/events/SimulationJobStatusEventRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.events;
1+
package org.vcell.api.types.events;
22

33
public class SimulationJobStatusEventRepresentation {
44

‎vcell-core/src/main/java/cbit/rmi/event/client/events/SimulationJobStatusRepresentation.java ‎vcell-api-types/src/main/java/org/vcell/api/types/events/SimulationJobStatusRepresentation.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package cbit.rmi.event.client.events;
1+
package org.vcell.api.types.events;
22

33
import java.util.Date;
44

‎vcell-core/src/main/java/cbit/rmi/event/client/DTOOldAPI.java ‎vcell-api-types/src/main/java/org/vcell/api/types/utils/DTOOldAPI.java

+8-7
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
1-
package cbit.rmi.event.client;
1+
package org.vcell.api.types.utils;
22

33
import cbit.rmi.event.DataJobEvent;
44
import cbit.rmi.event.ExportEvent;
55
import cbit.rmi.event.SimulationJobStatusEvent;
6-
import cbit.rmi.event.client.common.SimpleJobStatusRepresentation;
7-
import cbit.rmi.event.client.events.*;
86
import cbit.vcell.export.server.HumanReadableExportData;
97
import cbit.vcell.export.server.TimeSpecs;
108
import cbit.vcell.export.server.VariableSpecs;
@@ -15,6 +13,9 @@
1513
import cbit.vcell.solver.Simulation;
1614
import cbit.vcell.solver.VCSimulationIdentifier;
1715
import cbit.vcell.solver.server.SimulationMessage;
16+
import org.vcell.api.types.common.SimpleJobStatusRepresentation;
17+
import org.vcell.api.types.common.UserInfo;
18+
import org.vcell.api.types.events.*;
1819
import org.vcell.util.document.*;
1920

2021
import java.io.BufferedInputStream;
@@ -252,17 +253,17 @@ public static SimulationJobStatusEventRepresentation simulationJobStatusEventToJ
252253
return eventRep;
253254
}
254255

255-
public static cbit.rmi.event.client.common.UserInfo getApiUserInfo(UserInfo userInfo){
256-
cbit.rmi.event.client.common.UserInfo apiUserInfo = new cbit.rmi.event.client.common.UserInfo(
256+
public static UserInfo getApiUserInfo(org.vcell.util.document.UserInfo userInfo){
257+
UserInfo apiUserInfo = new UserInfo(
257258
(userInfo.id!=null) ? userInfo.id.toString() : null,
258259
userInfo.userid, userInfo.digestedPassword0.getString(), userInfo.email, userInfo.wholeName,
259260
userInfo.title, userInfo.company, userInfo.country, userInfo.notify, userInfo.insertDate);
260261
return apiUserInfo;
261262
}
262263

263264

264-
public static UserInfo fromApiUserInfo(cbit.rmi.event.client.common.UserInfo apiUserInfo) {
265-
UserInfo userInfo = new UserInfo();
265+
public static org.vcell.util.document.UserInfo fromApiUserInfo(UserInfo apiUserInfo) {
266+
org.vcell.util.document.UserInfo userInfo = new org.vcell.util.document.UserInfo();
266267
userInfo.id = new KeyValue(apiUserInfo.id);
267268
userInfo.userid = apiUserInfo.userid;
268269
userInfo.digestedPassword0 = UserLoginInfo.DigestedPassword.createAlreadyDigested(apiUserInfo.digestedPassword0);

‎vcell-api/pom.xml

+5
Original file line numberDiff line numberDiff line change
@@ -162,5 +162,10 @@
162162
<artifactId>joda-time</artifactId>
163163
<version>${joda-time.version}</version>
164164
</dependency>
165+
<dependency>
166+
<groupId>org.vcell</groupId>
167+
<artifactId>vcell-api-types</artifactId>
168+
<version>1.0.0</version>
169+
</dependency>
165170
</dependencies>
166171
</project>

‎vcell-api/src/main/java/org/vcell/rest/VCellApiApplication.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ public enum AuthenticationPolicy {
118118
public static final String SIMDATA = "simdata";
119119
public static final String SIMDATAID = "simdataid";
120120

121-
public static final String EVENTS = "events";
121+
public static final String EVENTS = "org/vcell/api/types";
122122
public static final String EVENTS_BEGINTIMESTAMP = "beginTimestamp";
123123

124124
public static final String N5DATA = "n5data";

‎vcell-api/src/main/java/org/vcell/rest/admin/AdminJobsRestlet.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package org.vcell.rest.admin;
22

3+
import org.vcell.api.types.common.SimpleJobStatusRepresentation;
34
import org.apache.logging.log4j.LogManager;
45
import org.apache.logging.log4j.Logger;
56
import org.restlet.Context;
@@ -12,14 +13,13 @@
1213
import org.restlet.data.Status;
1314
import org.restlet.engine.adapter.HttpRequest;
1415
import org.restlet.ext.json.JsonRepresentation;
15-
import cbit.rmi.event.client.common.SimpleJobStatusRepresentation;
16-
import cbit.rmi.event.client.DTOOldAPI;
1716
import org.vcell.rest.VCellApiApplication;
1817

1918
import com.google.gson.Gson;
2019

2120
import cbit.vcell.server.SimpleJobStatusQuerySpec;
2221
import cbit.vcell.server.SimulationJobStatus;
22+
import org.vcell.api.types.utils.DTOOldAPI;
2323

2424
public final class AdminJobsRestlet extends Restlet {
2525
private final static Logger lg = LogManager.getLogger(AdminJobsRestlet.class);

‎vcell-api/src/main/java/org/vcell/rest/events/EventsRestlet.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package org.vcell.rest.events;
22

3+
import org.vcell.api.types.events.EventWrapper;
34
import org.apache.logging.log4j.LogManager;
45
import org.apache.logging.log4j.Logger;
56
import org.restlet.Context;
@@ -12,7 +13,6 @@
1213
import org.restlet.data.Status;
1314
import org.restlet.engine.adapter.HttpRequest;
1415
import org.restlet.ext.json.JsonRepresentation;
15-
import cbit.rmi.event.client.events.EventWrapper;
1616
import org.vcell.rest.VCellApiApplication;
1717
import org.vcell.rest.VCellApiApplication.AuthenticationPolicy;
1818
import org.vcell.util.document.User;

0 commit comments

Comments
 (0)
Please sign in to comment.