Update of /cvsroot/webmacro/webmacro/src/org/webmacro/directive
In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv27323/src/org/webmacro/directive
Modified Files:
TypeDirective.java
Log Message:
Checkstyle: organise imports
Index: TypeDirective.java
===================================================================
RCS file: /cvsroot/webmacro/webmacro/src/org/webmacro/directive/TypeDirective.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** TypeDirective.java 29 Mar 2006 16:27:44 -0000 1.9
--- TypeDirective.java 20 Mar 2008 12:32:04 -0000 1.10
***************
*** 22,26 ****
package org.webmacro.directive;
! import org.webmacro.*;
import org.webmacro.engine.BuildContext;
import org.webmacro.engine.BuildException;
--- 22,33 ----
package org.webmacro.directive;
! import java.io.IOException;
!
! import org.webmacro.Broker;
! import org.webmacro.Context;
! import org.webmacro.FastWriter;
! import org.webmacro.Macro;
! import org.webmacro.PropertyException;
! import org.webmacro.TemplateVisitor;
import org.webmacro.engine.BuildContext;
import org.webmacro.engine.BuildException;
***************
*** 29,44 ****
import org.webmacro.util.Settings;
- import java.io.IOException;
-
/**
* TypeDirective allows the programmer (or template designer) to ensure
* objects placed into the <code>Context</code> are of the required class
! * type.<p>
! *
! * Syntax:<pre>
* #type [ required ] var-reference quoted-string
* </pre>
*
! * Examples:<pre>
* $MyName, if it exists in the context, <b>must</b> be a java.lang.String
* #type $MyName "java.lang.String"
--- 36,51 ----
import org.webmacro.util.Settings;
/**
* TypeDirective allows the programmer (or template designer) to ensure
* objects placed into the <code>Context</code> are of the required class
! * type.
! * <p>
! * Syntax:
! * <pre>
* #type [ required ] var-reference quoted-string
* </pre>
*
! * Examples:
! * <pre>
* $MyName, if it exists in the context, <b>must</b> be a java.lang.String
* #type $MyName "java.lang.String"
***************
*** 66,70 ****
*
* TypeDirective is <b>enabled by default</b>, however, it can be disabled
! * via your custom <code>WebMacro.properties</code> file:<pre>
* TypeDirective.Enabled = true | false
* </pre>
--- 73,78 ----
*
* TypeDirective is <b>enabled by default</b>, however, it can be disabled
! * via your custom <code>WebMacro.properties</code> file:
! * <pre>
* TypeDirective.Enabled = true | false
* </pre>
***************
*** 92,97 ****
/**
! * static method required by the WebMacro parser to provide
! * a descriptor about this directive
*/
public static DirectiveDescriptor getDescriptor ()
--- 100,105 ----
/**
! * Static method required by the WebMacro parser to provide
! * a descriptor about this directive.
*/
public static DirectiveDescriptor getDescriptor ()
***************
*** 101,115 ****
! /** the Context object we need to check the type of */
private Variable _object;
! /** the Class instance that _object is requried to be */
private Class _class;
! /** is the Variable required to be in the Context? */
private boolean _required;
/**
! * configure directive for this run and return 'this'
*/
public Object build (DirectiveBuilder builder, BuildContext bc) throws BuildException
--- 109,123 ----
! /** The Context object we need to check the type of. */
private Variable _object;
! /** The Class instance that _object is requried to be. */
private Class _class;
! /** Is the Variable required to be in the Context? */
private boolean _required;
/**
! * Configure directive for this run and return 'this'.
*/
public Object build (DirectiveBuilder builder, BuildContext bc) throws BuildException
***************
*** 179,183 ****
/**
! * The #type directive does not produce output
*/
public void write (FastWriter fw, Context context) throws IOException, PropertyException
--- 187,191 ----
/**
! * The #type directive does not produce output.
*/
public void write (FastWriter fw, Context context) throws IOException, PropertyException
***************
*** 237,239 ****
return clazz;
}
! }
\ No newline at end of file
--- 245,248 ----
return clazz;
}
! }
!
|