Coverage Report

##### Coverage Report - org.webmacro.engine.ParamBuilder

Classes in this File | Line Coverage | Branch Coverage | Complexity
ParamBuilder |
0% | 0/8
N/A | N/A
| 2.0;2

1 |  |
     /*
2 |  |
      * Copyright (C) 1998-2000 Semiotek Inc.  All Rights Reserved.
3 |  |
      *
4 |  |
      * Redistribution and use in source and binary forms, with or without
5 |  |
      * modification, are permitted under the terms of either of the following
6 |  |
      * Open Source licenses:
7 |  |
      *
8 |  |
      * The GNU General Public License, version 2, or any later version, as
9 |  |
      * published by the Free Software Foundation
10 |  |
      * (http://www.fsf.org/copyleft/gpl.html);
11 |  |
      *
12 |  |
      *  or
13 |  |
      *
14 |  |
      * The Semiotek Public License (http://webmacro.org/LICENSE.)
15 |  |
      *
16 |  |
      * This software is provided "as is", with NO WARRANTY, not even the
17 |  |
      * implied warranties of fitness to purpose, or merchantability. You
18 |  |
      * assume all risks and liabilities associated with its use.
19 |  |
      *
20 |  |
      * See www.webmacro.org for more information on the WebMacro project.
21 |  |
      */
22 |  |
23 |  |
24 |  |
     package org.webmacro.engine;
25 |  |
26 |  |
     /** Build from parameters. */
27 |  |
     public class ParamBuilder implements Builder
28 |  |
     {
29 |  |
30 |  |
         private Object[] _names;
31 |  |
32 |  |
         public ParamBuilder (Object[] names)
33 | 0 |
         {
34 | 0 |
             _names = names;
35 | 0 |
         }
36 |  |
37 |  |
         public final Object build (BuildContext bc)
38 |  |
                 throws BuildException
39 |  |
         {
40 |  |
             try
41 |  |
             {
42 | 0 |
                 Object ret = bc.get(_names);
43 |  |
                 // XXX: Filter me
44 | 0 |
                 return ret;
45 |  |
             }
46 | 0 |
             catch (Exception e)
47 |  |
             {
48 | 0 |
                 throw new BuildException("Property error occured during parameter "
49 |  |
                         + "build pocess: ", e);
50 |  |
             }
51 |  |
         }
52 |  |
53 |  |
         public String toString ()
54 |  |
         {
55 | 0 |
             return "param:" + Variable.makeName(_names);
56 |  |
         }
57 |  |
58 |  |
     }
59 |  |