Author: heiko.braun(a)jboss.com
Date: 2007-10-30 17:15:16 -0400 (Tue, 30 Oct 2007)
New Revision: 4944
Added:
stack/native/branches/rest/src/main/java/org/jboss/rs/runtime/
stack/native/branches/rest/src/main/java/org/jboss/rs/runtime/RuntimeContext.java
Removed:
stack/native/branches/rest/src/main/java/org/jboss/rs/model/EntityModel.java
stack/native/branches/rest/src/main/java/org/jboss/rs/model/RuntimeContext.java
Modified:
stack/native/branches/rest/src/main/java/org/jboss/rs/model/ResourceResolver.java
stack/native/branches/rest/src/test/java/org/jboss/test/rs/model/ResolverTestCase.java
Log:
Cleanup. Introduce runtime package
Deleted: stack/native/branches/rest/src/main/java/org/jboss/rs/model/EntityModel.java
===================================================================
---
stack/native/branches/rest/src/main/java/org/jboss/rs/model/EntityModel.java 2007-10-30
21:12:37 UTC (rev 4943)
+++
stack/native/branches/rest/src/main/java/org/jboss/rs/model/EntityModel.java 2007-10-30
21:15:16 UTC (rev 4944)
@@ -1,47 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.rs.model;
-
-/**
- * @author Heiko.Braun(a)jboss.com
- * @version $Revision$
- */
-public class EntityModel
-{
- Class implementation;
-
- public EntityModel(Class implementation)
- {
- this.implementation = implementation;
- }
-
- public Class getImplementation()
- {
- return implementation;
- }
-
-
- public String toString()
- {
- return "EntityModel {impl="+implementation+"}";
- }
-}
Modified:
stack/native/branches/rest/src/main/java/org/jboss/rs/model/ResourceResolver.java
===================================================================
---
stack/native/branches/rest/src/main/java/org/jboss/rs/model/ResourceResolver.java 2007-10-30
21:12:37 UTC (rev 4943)
+++
stack/native/branches/rest/src/main/java/org/jboss/rs/model/ResourceResolver.java 2007-10-30
21:15:16 UTC (rev 4944)
@@ -21,6 +21,8 @@
*/
package org.jboss.rs.model;
+import org.jboss.rs.runtime.RuntimeContext;
+
import java.util.ArrayList;
import java.util.Collections;
import java.util.Iterator;
Deleted: stack/native/branches/rest/src/main/java/org/jboss/rs/model/RuntimeContext.java
===================================================================
---
stack/native/branches/rest/src/main/java/org/jboss/rs/model/RuntimeContext.java 2007-10-30
21:12:37 UTC (rev 4943)
+++
stack/native/branches/rest/src/main/java/org/jboss/rs/model/RuntimeContext.java 2007-10-30
21:15:16 UTC (rev 4944)
@@ -1,63 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.rs.model;
-
-import org.jboss.rs.MethodHTTP;
-
-import java.util.List;
-
-/**
- * @author Heiko.Braun(a)jboss.com
- * @version $Revision$
- */
-public class RuntimeContext
-{
- private MethodHTTP requestMethod;
- private List<ResourceModel> rootResources;
- private String uri;
-
- private Object requestMediaType;
- private Object responseMediaType;
-
- public RuntimeContext(MethodHTTP requestMethod, String uri, List<ResourceModel>
rootResources)
- {
- this.requestMethod = requestMethod;
- this.rootResources = rootResources;
- this.uri = uri;
- }
-
- public MethodHTTP getRequestMethod()
- {
- return requestMethod;
- }
-
-
- public List<ResourceModel> getRootResources()
- {
- return rootResources;
- }
-
- public String getUri()
- {
- return uri;
- }
-}
Copied: stack/native/branches/rest/src/main/java/org/jboss/rs/runtime/RuntimeContext.java
(from rev 4943,
stack/native/branches/rest/src/main/java/org/jboss/rs/model/RuntimeContext.java)
===================================================================
--- stack/native/branches/rest/src/main/java/org/jboss/rs/runtime/RuntimeContext.java
(rev 0)
+++
stack/native/branches/rest/src/main/java/org/jboss/rs/runtime/RuntimeContext.java 2007-10-30
21:15:16 UTC (rev 4944)
@@ -0,0 +1,64 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.rs.runtime;
+
+import org.jboss.rs.MethodHTTP;
+import org.jboss.rs.model.ResourceModel;
+
+import java.util.List;
+
+/**
+ * @author Heiko.Braun(a)jboss.com
+ * @version $Revision$
+ */
+public class RuntimeContext
+{
+ private MethodHTTP requestMethod;
+ private List<ResourceModel> rootResources;
+ private String uri;
+
+ private Object requestMediaType;
+ private Object responseMediaType;
+
+ public RuntimeContext(MethodHTTP requestMethod, String uri, List<ResourceModel>
rootResources)
+ {
+ this.requestMethod = requestMethod;
+ this.rootResources = rootResources;
+ this.uri = uri;
+ }
+
+ public MethodHTTP getRequestMethod()
+ {
+ return requestMethod;
+ }
+
+
+ public List<ResourceModel> getRootResources()
+ {
+ return rootResources;
+ }
+
+ public String getUri()
+ {
+ return uri;
+ }
+}
Property changes on:
stack/native/branches/rest/src/main/java/org/jboss/rs/runtime/RuntimeContext.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified:
stack/native/branches/rest/src/test/java/org/jboss/test/rs/model/ResolverTestCase.java
===================================================================
---
stack/native/branches/rest/src/test/java/org/jboss/test/rs/model/ResolverTestCase.java 2007-10-30
21:12:37 UTC (rev 4943)
+++
stack/native/branches/rest/src/test/java/org/jboss/test/rs/model/ResolverTestCase.java 2007-10-30
21:15:16 UTC (rev 4944)
@@ -24,11 +24,11 @@
import junit.framework.TestCase;
import org.jboss.rs.ResourceRegistry;
import org.jboss.rs.MethodHTTP;
+import org.jboss.rs.runtime.RuntimeContext;
import org.jboss.rs.model.ResourceModel;
import org.jboss.rs.model.ResourceModelParser;
import org.jboss.rs.model.ResourceResolver;
import org.jboss.rs.model.ResourceMethod;
-import org.jboss.rs.model.RuntimeContext;
import java.util.List;
import java.lang.reflect.Method;