rt/launcher/src/main/java/org/apidesign/bck2brwsr/launcher/InvocationContext.java
1.1 --- a/rt/launcher/src/main/java/org/apidesign/bck2brwsr/launcher/InvocationContext.java Sun Apr 07 22:30:45 2013 +0200
1.2 +++ b/rt/launcher/src/main/java/org/apidesign/bck2brwsr/launcher/InvocationContext.java Mon Apr 08 16:51:30 2013 +0200
1.3 @@ -55,11 +55,11 @@
1.4 /** HTTP resource to be available during execution. An invocation may
1.5 * perform an HTTP query and obtain a resource relative to the page.
1.6 */
1.7 - public void addHttpResource(String relativePath, String mimeType, InputStream content) {
1.8 - if (relativePath == null || mimeType == null || content == null) {
1.9 + public void addHttpResource(String relativePath, String mimeType, String[] parameters, InputStream content) {
1.10 + if (relativePath == null || mimeType == null || content == null || parameters == null) {
1.11 throw new NullPointerException();
1.12 }
1.13 - resources.add(new Resource(content, mimeType, relativePath));
1.14 + resources.add(new Resource(content, mimeType, relativePath, parameters));
1.15 }
1.16
1.17 /** Invokes the associated method.
1.18 @@ -100,12 +100,16 @@
1.19 final InputStream httpContent;
1.20 final String httpType;
1.21 final String httpPath;
1.22 + final String[] parameters;
1.23
1.24 - Resource(InputStream httpContent, String httpType, String httpPath) {
1.25 + Resource(InputStream httpContent, String httpType, String httpPath,
1.26 + String[] parameters
1.27 + ) {
1.28 httpContent.mark(Integer.MAX_VALUE);
1.29 this.httpContent = httpContent;
1.30 this.httpType = httpType;
1.31 this.httpPath = httpPath;
1.32 + this.parameters = parameters;
1.33 }
1.34 }
1.35 }