Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Wire in the new XML parser Deploy stuff
git-svn-id: http://anonsvn.jboss.org/repos/weld/ri/trunk@2110 1c488680-804c-0410-94cd-c6b725194a0e
- Loading branch information
Showing
8 changed files
with
140 additions
and
66 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
impl/src/main/java/org/jboss/webbeans/mock/MockXmlEnvironment.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
package org.jboss.webbeans.mock; | ||
|
||
import java.net.URL; | ||
|
||
import org.jboss.webbeans.bootstrap.api.ServiceRegistry; | ||
import org.jboss.webbeans.bootstrap.api.helpers.SimpleServiceRegistry; | ||
import org.jboss.webbeans.resources.DefaultResourceLoader; | ||
import org.jboss.webbeans.resources.spi.ResourceLoader; | ||
import org.jboss.webbeans.xml.XmlEnvironmentImpl; | ||
|
||
public class MockXmlEnvironment extends XmlEnvironmentImpl | ||
{ | ||
|
||
private static final ServiceRegistry services; | ||
|
||
static | ||
{ | ||
services = new SimpleServiceRegistry(); | ||
services.add(ResourceLoader.class, new DefaultResourceLoader()); | ||
} | ||
|
||
private final Iterable<URL> beansXmlUrls; | ||
|
||
public MockXmlEnvironment(Iterable<URL> beansXmlUrls) | ||
{ | ||
super(services); | ||
this.beansXmlUrls = beansXmlUrls; | ||
} | ||
|
||
@Override | ||
public Iterable<URL> getBeansXmlUrls() | ||
{ | ||
return beansXmlUrls; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
impl/src/main/java/org/jboss/webbeans/xml/XmlEnvironment.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
package org.jboss.webbeans.xml; | ||
|
||
import java.lang.annotation.Annotation; | ||
import java.net.URL; | ||
import java.util.List; | ||
|
||
import org.jboss.webbeans.introspector.AnnotatedAnnotation; | ||
import org.jboss.webbeans.introspector.AnnotatedClass; | ||
|
||
public interface XmlEnvironment | ||
{ | ||
|
||
public List<AnnotatedClass<?>> getClasses(); | ||
|
||
public List<AnnotatedAnnotation<?>> getAnnotations(); | ||
|
||
public Iterable<URL> getBeansXmlUrls(); | ||
|
||
public <T> AnnotatedClass<? extends T> loadClass(String className, Class<T> expectedType); | ||
|
||
public <T extends Annotation> AnnotatedAnnotation<? extends T> loadAnnotation(String className, Class<T> expectedType); | ||
|
||
public List<Class<? extends Annotation>> getEnabledDeploymentTypes(); | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters