Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Tapestry Wiki" for 
change notification.

The following page has been changed by ErikVullings:
http://wiki.apache.org/tapestry/MoreFrequentlyAskedQuestions

------------------------------------------------------------------------------
  public abstract String getEvent(); 
  }}}
  
+ HowardLewisShip:  I call this the ''Tapestry Bucket Brigade''.
+ 
  == I just created a new page and now I get a 'class instantiation problem'.  
Why can’t it instantiate my class? ==
  
  Most likely you created your class abstract when it didn’t need to be.  
Tapestry doesn’t create an enhanced subclass if there are no 
<property-specification> elements.  A concrete class is never created by 
Tapestry in this case and since abstract classes cannot be instantiated, this 
exception pops up.  You either need to create a <property-specification> 
element or make your class concrete by removing the abstract identifier.
  
+ HowardLewisShip: This is a bug fixed in Tapestry 3.0.1.  In 3.0.1, if you 
class is abstract but there is not need for enhancement, Tapestry will quitely 
enhance your class anyway, just so it isn't abstract.
+ 
  == How can I share data across two Tapestry applications? ==
  
  Even if you’re running two Tapestry applications within the same Application 
Server (i.e. Tomcat) you can’t share data between them within the Application 
Server.  You can merge the two applications together into one application and 
then share data through singleton objects within the Application Server.  
Alternatively the two applications can share data at a lower level common 
level, i.e. the operating system (message passing) or a database.
+ 
+ HowardLewisShip: It is possible to have two different applications within the 
same WAR, never mind, EAR, in which case, singletons can be stored in the 
ServletContext. If you ''carefully'' check the specification and template file 
resolution rules (in the Users Guide), you can see how to keep the pieces 
seperate from each other.  However, this is not widely used and there's a 
possibility it won't make it into Tapestry 3.1.
  
  == What is Spindle? ==
  
@@ -119, +125 @@

  {{{
  Public void submit() {
        // getVisit() will need to be casted to the defined Visit class
-       Some.example.Visit visit = (Some.example.Visit)getPage().getVisit();
+       some.example.Visit visit = (some.example.Visit)getPage().getVisit();
  }
  }}}
  
  == How do I make a property in a Component persistent? ==
  
  Pages support persistent properties so place the persistent property in the 
encompassing Page and pass it into the Component.  The property will remain 
persistent and be passed into the Component as a parameter.  The Component will 
need not know, or care, that the property is persistent.
+ 
+ HowardLewisShip: The above is technically correct, but 
<property-specification> inside a component can still use the persist="yes" 
attribute and be persistent!  The mechanism is exactly the same for pages as it 
is for components, just the HttpSession attribute key is a bit longer (it 
incorporates the page name, the component id path and the property name).
  
  
  == Where can I find a Tapestry tutorial? ==

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to