LEONARDI Application Composer - 8.9.0.40 by W4 S.A.

leon.app.behavior
Class LyPrintModelBehavior

java.lang.Object
  extended by leon.app.behavior.LyBehavior
      extended by leon.app.behavior.LyActionBehavior
          extended by leon.app.behavior.LyPrintModelBehavior
All Implemented Interfaces:
LyActionBehaviorInterface, LyBehaviorInterface, LyGetSessionInterface

public class LyPrintModelBehavior
extends LyActionBehavior

This class implements the default behavior for a LyPrintModelController.

See Also:
LyPrintController

Field Summary
static java.lang.String __VERSION
          File version
 
Constructor Summary
LyPrintModelBehavior()
          Default constructor.
 
Method Summary
 java.lang.String completePrint(LyPrintModelController printer, java.lang.String result)
          Method invoked to modify the result string.
 java.lang.String getCommand(LyPrintModelController printer)
          Get the command string to execute at the end of the model printing.
 java.lang.String getModel(LyPrintModelController printer)
          Gets the model file name and path.
 java.lang.String getOutput(LyPrintModelController printer)
          Gets the output file name and path.
 LyContentReplacer preparePrint(LyPrintModelController printer, LyContentReplacer replacer)
          Method invoked to configure the content replacer.
 boolean printBegin(LyPrintModelController printer)
          Method invoked before printing the object or object list.
 boolean printEnd(LyPrintModelController printer)
          Method invoked after printing the object or object list.
 
Methods inherited from class leon.app.behavior.LyActionBehavior
endAction, getClientContext, getContextTitle, getHelpFile, getImage, getImageTooltip, getKeyValue, getMenuItemImage, getTitle, reset, startAction
 
Methods inherited from class leon.app.behavior.LyBehavior
free, getSession, handleDemand, init
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface leon.app.behaviorinterface.LyBehaviorInterface
free, handleDemand, init
 

Field Detail

__VERSION

public static final java.lang.String __VERSION
File version

See Also:
Constant Field Values
Constructor Detail

LyPrintModelBehavior

public LyPrintModelBehavior()
Default constructor.

Method Detail

printBegin

public boolean printBegin(LyPrintModelController printer)
Method invoked before printing the object or object list.
The default implementation does nothing and return false.

Parameters:
printer - current LySimplePrintController instance
Returns:
true if the process is done (stop generic behavior) false otherwise.

getModel

public java.lang.String getModel(LyPrintModelController printer)
Gets the model file name and path.
The default implementation gets the given controller action parameter defining the model, expands it and returns it.

Parameters:
printer - current LyPrintModelController instance
Returns:
the model file, by default the "_model" parameter of the controller action

getOutput

public java.lang.String getOutput(LyPrintModelController printer)
Gets the output file name and path.
The default implementation gets the given controller action parameter defining the output file, if it is not null expands it, else creates a temporary one.

Parameters:
printer - current LyPrintModelController instance
Returns:
the output file, by default the _output parameter of the action

getCommand

public java.lang.String getCommand(LyPrintModelController printer)
Get the command string to execute at the end of the model printing.
The default implementation gets the given controller action parameter defining the command.

Parameters:
printer - current LyPrintModelController instance
Returns:
the command string for exec(), by default the _command parameter of the action

preparePrint

public LyContentReplacer preparePrint(LyPrintModelController printer,
                                      LyContentReplacer replacer)
Method invoked to configure the content replacer.
The default implementation does nothing and return the given replacer.

Parameters:
printer - current LyPrintModelController instance
replacer - current replacer
Returns:
the configured content replacer

completePrint

public java.lang.String completePrint(LyPrintModelController printer,
                                      java.lang.String result)
Method invoked to modify the result string.
The default implementation does nothing and return the given result.

Parameters:
printer - current LyPrintModelController instance
result - string result
Returns:
the string result

printEnd

public boolean printEnd(LyPrintModelController printer)
Method invoked after printing the object or object list.
The default implementation does nothing and return false.

Parameters:
printer - current LySimplePrintController instance
Returns:
true if the process is done (stop generic behavior) false otherwise.

(c) January 2013 - W4 S.A.

Website: W4 S.A., contact us: support@w4global.com