[
https://issues.apache.org/jira/browse/DELTASPIKE-399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13848861#comment-13848861
]
Gerhard Petracek edited comment on DELTASPIKE-399 at 12/16/13 7:30 AM:
-----------------------------------------------------------------------
#1 ExternalResourceLiteral needs to be in org.apache.deltaspike.core.api.literal
#2 imo XMLProperties doesn't fit to what we have in other parts
#3 rename ExternalResourceProvider#getPriority to #getOrdinal (which is the
term we are using)
#4 so far we haven't used #getCanonicalName (-> please start a discussion or
change it)
#5 we don't use @author
#6 ResourceLoaderExtension is a concept we don't use right now (we should use
it everywhere or nowhere)
#7 so far we never have InjectionPoint in a spi and it isn't used currently.
since it exposes internals, we should remove it imo
#8 using #getResources but just returning the first InputStream isn't that nice
(+ if there are multiple urls, it can lead to random results)
was (Author: gpetracek):
#1 ExternalResourceLiteral needs to be in org.apache.deltaspike.core.api.literal
#2 imo XMLProperties doesn't fit to what we have in other parts
#3 rename ExternalResourceProvider#getPriority to #getOrdinal (which is the
term we are using)
#4 so far we haven't used #getCanonicalName (-> please start a discussion or
change it)
#5 we don't use @author
#6 ResourceLoaderExtension is a concept we don't use right now (we should use
it everywhere or nowhere)
#7 so far we never have InjectionPoint in a spi and it isn't used currently.
since it exposes internals, we should remove it imo
#7 using #getResources but just returning the first InputStream isn't that nice
(+ if there are multiple urls, it can lead to random results)
> Incorporate Solder's ResourceLoader features into DeltaSpike
> ------------------------------------------------------------
>
> Key: DELTASPIKE-399
> URL: https://issues.apache.org/jira/browse/DELTASPIKE-399
> Project: DeltaSpike
> Issue Type: New Feature
> Components: Core
> Affects Versions: 0.4
> Reporter: Aaron Siri
> Assignee: John D. Ament
> Priority: Minor
> Fix For: 0.6
>
>
> Seam 3's Solder module had some nice resource loading functionality within
> the org.jboss.solder.resourceLoader packages. With it you could do the
> following:
> // Load a properties file
> @Inject @Resource("app.properties")
> private Properties appProperties;
> or:
> @Inject
> private ResourceProvider resourceProvider
> public Properties getHostProperties() {
> String hostname = java.net.InetAddress.getLocalHost().getHostName();
> return resourceProvider.loadPropertiesBundle(hostname + ".properties");
> }
--
This message was sent by Atlassian JIRA
(v6.1.4#6159)