helma/modules/jala/docs/jala.Form.Component.Image.html

376 lines
13 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN""http://www.w3.org/TR/REC-html40/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<TITLE>
jala.Form.Component.Image
</TITLE>
<LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
</HEAD>
<SCRIPT>
function asd()
{
parent.document.title="jala.Form.Component.Image";
}
</SCRIPT>
<BODY BGCOLOR="white" onload="asd();">
<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_bottom"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary-Form.js.html"><FONT CLASS="NavBarFont1"><B>File</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev">&nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
<!--TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"--> <!--A HREF="deprecated-list.html"--><!--FONT CLASS="NavBarFont1">Deprecated</FONT--><!--/A--><!--&nbsp;</TD-->
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"--><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
<B>Jala 1.3</B>
</EM>
</TD
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="jala.Form.Component.Hidden.html"><B>PREV CLASS</B></A><!--
NEXT CLASS
-->
&nbsp;<A HREF="jala.Form.Component.Input.html"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="index.html" TARGET="_top"><B>FRAMES</B></A> &nbsp;
&nbsp;<A HREF="jala.Form.Component.Image.html" TARGET="_top"><B>NO FRAMES</B></A> &nbsp;
&nbsp;
<SCRIPT>
<!--
if(window==top) {
document.writeln('<A HREF="allclasses-noframe.html" TARGET=""><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="allclasses-noframe.html" TARGET=""><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY:&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>Class jala.Form.Component.Image</H2>
<PRE>Object
|
+--<a href='jala.Form.Component.Input.html'>jala.Form.Component.Input</a>
|
+--<a href='jala.Form.Component.File.html'>jala.Form.Component.File</a>
|
+--<b>jala.Form.Component.Image</b>
</PRE>
<HR>
<DL>
<!-- Class definition -->
<DT>class
<B>jala.Form.Component.Image</B>
<DT>extends <a href='jala.Form.Component.File.html'>jala.Form.Component.File</a>
</DL>
<P>
<BR/>Subclass of jala.Form.Component.File which renders a file upload
and validates uploaded files as images.
<BR/><I>Defined in <a href='overview-summary-Form.js.html'>Form.js</a></I><BR/><BR/>
</P>
<HR>
<!-- ======== NESTED CLASS SUMMARY ======== -->
<!-- ======== END NESTED CLASS SUMMARY ======== -->
<!-- =========== FIELD SUMMARY =========== -->
<!-- =========== END FIELD SUMMARY =========== -->
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD>
<CODE>
<B>
<A HREF="jala.Form.Component.Image.html#jala.Form.Component.Image()">jala.Form.Component.Image</A>
</B>
()
</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
Creates a new Image component instance
</TD>
</TR>
</TABLE>
<!-- ======== END CONSTRUCTOR SUMMARY ======== -->
&nbsp;
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Method Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%">
<FONT SIZE="-1">
<CODE>&nbsp;String</CODE>
</FONT>
</TD>
<TD>
<CODE>
<B>
<A HREF="#checkRequirements">checkRequirements</A></B>(&lt;Object&gt; reqData)
</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
Validates an image upload by making sure it's there (if REQUIRE is set),
checking the file size, the content type and by trying to construct an image.
</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class <a href="jala.Form.Component.File.html">jala.Form.Component.File</a></B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>
<!-- Inherited methods -->
<a href="jala.Form.Component.File.html#renderControls">renderControls</a>
</CODE></TD>
</TR>
</TABLE>
&nbsp;
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class <a href="jala.Form.Component.Input.html">jala.Form.Component.Input</a></B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>
<!-- Inherited methods -->
<a href="jala.Form.Component.Input.html#validate">validate</a>, <a href="jala.Form.Component.Input.html#save">save</a>, <a href="jala.Form.Component.Input.html#getValue">getValue</a>, <a href="jala.Form.Component.Input.html#setValue">setValue</a>, <a href="jala.Form.Component.Input.html#render">render</a>, <a href="jala.Form.Component.Input.html#renderError">renderError</a>, <a href="jala.Form.Component.Input.html#renderLabel">renderLabel</a>, <a href="jala.Form.Component.Input.html#renderHelp">renderHelp</a>, <a href="jala.Form.Component.Input.html#render_macro">render_macro</a>, <a href="jala.Form.Component.Input.html#controls_macro">controls_macro</a>, <a href="jala.Form.Component.Input.html#error_macro">error_macro</a>, <a href="jala.Form.Component.Input.html#label_macro">label_macro</a>, <a href="jala.Form.Component.Input.html#help_macro">help_macro</a>, <a href="jala.Form.Component.Input.html#id_macro">id_macro</a>, <a href="jala.Form.Component.Input.html#name_macro">name_macro</a>, <a href="jala.Form.Component.Input.html#type_macro">type_macro</a>, <a href="jala.Form.Component.Input.html#class_macro">class_macro</a>, <a href="jala.Form.Component.Input.html#getControlAttributes">getControlAttributes</a>, <a href="jala.Form.Component.Input.html#checkLength">checkLength</a>, <a href="jala.Form.Component.Input.html#parseValue">parseValue</a>
</CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>
<!-- ========== END METHOD SUMMARY =========== -->
<!-- ============ FIELD DETAIL START =========== -->
<!-- ============ FIELD DETAIL END =========== -->
<!-- ========= CONSTRUCTOR DETAIL START ======== -->
<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1>
<FONT SIZE="+2"><B>Constructor Detail</B></FONT>
</TD>
</TR>
</TABLE>
<A NAME="jala.Form.Component.Image()"><!-- --></A><H3>
jala.Form.Component.Image</H3>
<PRE><B>jala.Form.Component.Image</B>()</PRE>
<UL>
Creates a new Image component instance
</UL>
<UL>
<B>Parameters:</B>
<UL><CODE>name</CODE> - Name of the component, used as name of the html controls.
</UL>
</UL>
<!-- Constructor return value(s) -->
<UL>
<B>Returns:</B>
<UL>
A newly created Image component
</UL>
</UL>
<!-- End constructor return value(s) -->
<!-- ADDITIONAL ATTRIBUTES -->
<HR/>
<!-- END ADDITIONAL ATTRIBUTES -->
<!-- ========= CONSTRUCTOR DETAIL END ======== -->
<!-- ============ METHOD DETAIL START ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Method Detail</B></FONT>
</TD>
</TR>
</TABLE>
<!-- One single method detail entry -->
<A NAME="checkRequirements"><!-- --></A>
<H3>checkRequirements</H3>
<PRE>String <B>checkRequirements</B>(&lt;Object&gt; reqData)</PRE>
<UL>Validates an image upload by making sure it's there (if REQUIRE is set),
checking the file size, the content type and by trying to construct an image.
If the file is an image, width and height limitations set by require are
checked.</UL>
<!-- METHOD PARAMETERS START -->
<UL>
<B>Parameters:</B>
<UL><CODE>reqData</CODE> - request data
</UL>
</UL>
<!-- METHOD PARAMETERS END -->
<!-- ADDITIONAL ATTRIBUTES START -->
<!-- ADDITIONAL ATTRIBUTES END -->
<HR>
<!-- ============ METHOD DETAIL END ========== -->
<!-- ========= END OF CLASS DATA ========= -->
<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_bottom"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary-Form.js.html"><FONT CLASS="NavBarFont1"><B>File</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><b>Tree</b></FONT></A>&nbsp;</TD>
<!--TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"--> <!--A HREF="deprecated-list.html"--><!--FONT CLASS="NavBarFont1">Deprecated</FONT--><!--/A--><!--&nbsp;</TD-->
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
<B>Jala 1.3</B>
</EM>
</TD
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="jala.Form.Component.Hidden.html"><B>PREV CLASS</B></A><!--
NEXT CLASS
-->
&nbsp;<A HREF="jala.Form.Component.Input.html"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="index.html" TARGET="_top"><B>FRAMES</B></A> &nbsp;
&nbsp;<A HREF="jala.Form.Component.Image.html" TARGET="_top"><B>NO FRAMES</B></A> &nbsp;
&nbsp;
<SCRIPT>
<!--
if(window==top) {
document.writeln('<A HREF="allclasses-noframe.html" TARGET=""><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="allclasses-noframe.html" TARGET=""><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY:&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->
<HR>
<FONT SIZE="-1">
</FONT>
<div class="jsdoc_ctime">Documentation generated by <a href="http://jsdoc.sourceforge.net/" target="_parent">JSDoc</a> on Tue Jan 8 15:45:31 2008</div>
</BODY>
</HTML>