Clover coverage report - Code Coverage for tapestry release 4.0-alpha-2
Coverage timestamp: Thu May 5 2005 09:57:44 EDT
file stats: LOC: 247   Methods: 0
NCLOC: 51   Classes: 1
30 day Evaluation Version distributed via the Maven Jar Repository. Clover is not free. You have 30 days to evaluate it. Please visit http://www.thecortex.net/clover to obtain a licensed version of Clover
 
 Source file Conditionals Statements Methods TOTAL
Infrastructure.java - - - -
coverage
 1   
 // Copyright 2004, 2005 The Apache Software Foundation
 2   
 //
 3   
 // Licensed under the Apache License, Version 2.0 (the "License");
 4   
 // you may not use this file except in compliance with the License.
 5   
 // You may obtain a copy of the License at
 6   
 //
 7   
 //     http://www.apache.org/licenses/LICENSE-2.0
 8   
 //
 9   
 // Unless required by applicable law or agreed to in writing, software
 10   
 // distributed under the License is distributed on an "AS IS" BASIS,
 11   
 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 12   
 // See the License for the specific language governing permissions and
 13   
 // limitations under the License.
 14   
 
 15   
 package org.apache.tapestry.services;
 16   
 
 17   
 import java.util.Locale;
 18   
 
 19   
 import org.apache.hivemind.ClassResolver;
 20   
 import org.apache.hivemind.Resource;
 21   
 import org.apache.tapestry.describe.HTMLDescriber;
 22   
 import org.apache.tapestry.engine.IPageSource;
 23   
 import org.apache.tapestry.engine.IPropertySource;
 24   
 import org.apache.tapestry.engine.IScriptSource;
 25   
 import org.apache.tapestry.engine.ISpecificationSource;
 26   
 import org.apache.tapestry.engine.state.ApplicationStateManager;
 27   
 import org.apache.tapestry.error.ExceptionPresenter;
 28   
 import org.apache.tapestry.error.RequestExceptionReporter;
 29   
 import org.apache.tapestry.listener.ListenerMapSource;
 30   
 import org.apache.tapestry.markup.MarkupWriterSource;
 31   
 import org.apache.tapestry.spec.IApplicationSpecification;
 32   
 import org.apache.tapestry.web.WebRequest;
 33   
 import org.apache.tapestry.web.WebResponse;
 34   
 
 35   
 /**
 36   
  * Tapestry infrastructure ... key services required by the {@link org.apache.tapestry.IEngine}
 37   
  * instance.
 38   
  * 
 39   
  * @author Howard Lewis Ship
 40   
  * @since 4.0
 41   
  */
 42   
 public interface Infrastructure
 43   
 {
 44   
     /**
 45   
      * Initializes the Infrastructure for a particular mode.
 46   
      * 
 47   
      * @throws IllegalStateException
 48   
      *             if the Infrastructure has already been initialized.
 49   
      */
 50   
 
 51   
     public void initialize(String mode);
 52   
 
 53   
     /**
 54   
      * Returns a named property.
 55   
      * 
 56   
      * @throws IllegalStateException
 57   
      *             if the Infrastructure has not yet been initialized.
 58   
      * @throws org.apache.hivemind.ApplicationRuntimeException
 59   
      *             if no value has been contributed for specified property name.
 60   
      */
 61   
 
 62   
     public Object getProperty(String propertyName);
 63   
 
 64   
     /**
 65   
      * Returns the {@link org.apache.tapestry.spec.IApplicationSpecification} for the current
 66   
      * application.
 67   
      */
 68   
 
 69   
     public IApplicationSpecification getApplicationSpecification();
 70   
 
 71   
     /**
 72   
      * Returns an {@link IPropertySource} configured to search the application specification,
 73   
      * etc. See <code>tapestry.ApplicationPropertySource</code>.
 74   
      */
 75   
     public IPropertySource getApplicationPropertySource();
 76   
 
 77   
     /**
 78   
      * Returns an {@link IPropertySource}&nbsp;configured to search the servlet, servlet context,
 79   
      * and factory defaults.
 80   
      */
 81   
 
 82   
     public IPropertySource getGlobalPropertySource();
 83   
 
 84   
     /**
 85   
      * Returns the coordinator to be notified of reset events (which will, in turn, notify other
 86   
      * services that they should discard cached data).
 87   
      */
 88   
 
 89   
     public ResetEventCoordinator getResetEventCoordinator();
 90   
 
 91   
     /**
 92   
      * Returns the source of component message bundles.
 93   
      */
 94   
 
 95   
     public ComponentMessagesSource getComponentMessagesSource();
 96   
 
 97   
     /**
 98   
      * Returns component or page template contents.
 99   
      */
 100   
 
 101   
     public TemplateSource getTemplateSource();
 102   
 
 103   
     /**
 104   
      * Returns the source of all application, page, component and library specifications.
 105   
      */
 106   
 
 107   
     public ISpecificationSource getSpecificationSource();
 108   
 
 109   
     /**
 110   
      * Returns a generic, shared ObjectPool instance.
 111   
      */
 112   
     public ObjectPool getObjectPool();
 113   
 
 114   
     /**
 115   
      * Returns the source for pages. The source is a cache of pages, but also can create new
 116   
      * instances when needed.
 117   
      */
 118   
 
 119   
     public IPageSource getPageSource();
 120   
 
 121   
     /**
 122   
      * Returns the ClassResolver used by the Tapestry HiveMind module, which should be sufficient
 123   
      * for use throughout the application.
 124   
      */
 125   
 
 126   
     public ClassResolver getClassResolver();
 127   
 
 128   
     /**
 129   
      * The DataSqueezer, used when constructing and decoding values stored in URLs (as query
 130   
      * parameters or hidden form fields).
 131   
      */
 132   
 
 133   
     public DataSqueezer getDataSqueezer();
 134   
 
 135   
     /**
 136   
      * The source for ready-to-execute versions of Tapestry script templates.
 137   
      */
 138   
 
 139   
     public IScriptSource getScriptSource();
 140   
 
 141   
     /**
 142   
      * The object from which engine services are obtained.
 143   
      */
 144   
 
 145   
     public ServiceMap getServiceMap();
 146   
 
 147   
     /**
 148   
      * Service used to report exceptions to the console.
 149   
      */
 150   
 
 151   
     public RequestExceptionReporter getRequestExceptionReporter();
 152   
 
 153   
     /**
 154   
      * Renders the active page as the response.
 155   
      */
 156   
 
 157   
     public ResponseRenderer getResponseRenderer();
 158   
 
 159   
     /**
 160   
      * Constructs {@link org.apache.tapestry.engine.ILink}&nbsp;instances for
 161   
      * {@link org.apache.tapestry.engine.IEngineService}s.
 162   
      */
 163   
 
 164   
     public LinkFactory getLinkFactory();
 165   
 
 166   
     /**
 167   
      * Used by the {@link org.apache.tapestry.IEngine}&nbsp;to create instances of
 168   
      * {@link org.apache.tapestry.IRequestCycle}.
 169   
      */
 170   
 
 171   
     public RequestCycleFactory getRequestCycleFactory();
 172   
 
 173   
     /**
 174   
      * Accesses application state objects (Visit and Global from Tapestry 3.0, but now more can be
 175   
      * created).
 176   
      */
 177   
 
 178   
     public ApplicationStateManager getApplicationStateManager();
 179   
 
 180   
     /**
 181   
      * Returns the request for the current request cycle.
 182   
      */
 183   
 
 184   
     public WebRequest getRequest();
 185   
 
 186   
     /**
 187   
      * Returns the response for the current request cycle.
 188   
      */
 189   
 
 190   
     public WebResponse getResponse();
 191   
 
 192   
     /**
 193   
      * Returns the context path, which identifies the application within the application server.
 194   
      * Context path should be used as a prefix for any URLs generated. The context path may be the
 195   
      * empty string, and will not end in a slash (servlet paths should start with a slash).
 196   
      */
 197   
 
 198   
     public String getContextPath();
 199   
 
 200   
     /**
 201   
      * Returns the application's id; a unique name that is incorporated into various session
 202   
      * attribute keys and into certain paths when searching for resources. For a servlet-based
 203   
      * Tapestry application, the id is the name of the servlet.
 204   
      */
 205   
 
 206   
     public String getApplicationId();
 207   
 
 208   
     /**
 209   
      * Returns the root context resource, which is the starting point when looking for resources
 210   
      * within the application.
 211   
      */
 212   
 
 213   
     public Resource getContextRoot();
 214   
 
 215   
     /**
 216   
      * Returns an object used to access component meta-data properties.
 217   
      */
 218   
 
 219   
     public ComponentPropertySource getComponentPropertySource();
 220   
 
 221   
     /**
 222   
      * Invoked when the locale for the current thread is changed.
 223   
      * 
 224   
      * @see org.apache.tapestry.IEngine#setLocale(Locale)
 225   
      */
 226   
 
 227   
     public void setLocale(Locale value);
 228   
 
 229   
     public String getOutputEncoding();
 230   
 
 231   
     public MarkupWriterSource getMarkupWriterSource();
 232   
 
 233   
     public HTMLDescriber getHTMLDescriber();
 234   
 
 235   
     /**
 236   
      * Responsible for presenting an exception error report to the user.
 237   
      */
 238   
 
 239   
     public ExceptionPresenter getExceptionPresenter();
 240   
 
 241   
     /**
 242   
      * The source for {@link org.apache.tapestry.listener.ListenerMap}s, for components or other
 243   
      * objects.
 244   
      */
 245   
 
 246   
     public ListenerMapSource getListenerMapSource();
 247   
 }