[shrinkwrap-issues] [JBoss JIRA] Resolved: (SHRINKWRAP-165) Create StringAsset

Andrew Lee Rubinger (JIRA) jira-events at lists.jboss.org
Mon May 3 14:41:05 EDT 2010


     [ https://jira.jboss.org/jira/browse/SHRINKWRAP-165?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Lee Rubinger resolved SHRINKWRAP-165.
--------------------------------------------

    Fix Version/s: 1.0.0-alpha-10
       Resolution: Done
         Assignee: Andrew Lee Rubinger  (was: Ken Gullaksen)


Applied Dan's patch.  Probably we don't need to supply a charset.  Also removed the ctor to create a StringAsset from an InputStream:

1) For that we do need to know what charset to read in as (it's UTF-8 under the hood, but that wasn't documented)
2) No test for it
3) I assume folks will instead supply a ByteArrayAsset or similar, is there a use case for this?

If I'm wrong in removing that ctor someone yell at me and we'll open another issue :)

> Create StringAsset
> ------------------
>
>                 Key: SHRINKWRAP-165
>                 URL: https://jira.jboss.org/jira/browse/SHRINKWRAP-165
>             Project: ShrinkWrap
>          Issue Type: Feature Request
>          Components: api
>            Reporter: Andrew Lee Rubinger
>            Assignee: Andrew Lee Rubinger
>             Fix For: 1.0.0-alpha-10
>
>         Attachments: SHRINKWRAP-165-v1.txt
>
>
> Create the functional equivalent of:
> new Asset()
>       {
>          @Override
>          public InputStream openStream()
>          {
>             return new ByteArrayInputStream("Some String".getBytes());
>          }
>       }
> User code should look like:
> new StringAsset("string");
> new StringAsset("string",Charset);

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the shrinkwrap-issues mailing list