📄 saver.html
字号:
the supplied File object.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>file</CODE> - the File<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - if an error occurs support loading from a File. <pre><jml> public_normal_behavior requires: file != null && (* file exists *); modifiable: model_sourceSupplied, model_structureDetermined; ensures: model_sourceSupplied == true && model_structureDetermined == false; also public_exceptional_behavior requires: file == null || (* file does not exist *); signals: (IOException); </jml></pre></DL></DD></DL><HR><A NAME="setDestination(java.io.OutputStream)"><!-- --></A><H3>setDestination</H3><PRE>public void <B>setDestination</B>(java.io.OutputStream output) throws java.io.IOException</PRE><DL><DD>Resets the Saver object and sets the destination to be the supplied InputStream.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>output</CODE> - the output stream<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - if this Loader doesn't support loading from a File.</DL></DD></DL><HR><A NAME="setRetrieval(int)"><!-- --></A><H3>setRetrieval</H3><PRE>public void <B>setRetrieval</B>(int mode)</PRE><DL><DD>Sets the retrieval mode<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>mode</CODE> - an integer representing a retrieval mode</DL></DD></DL><HR><A NAME="getFileExtension()"><!-- --></A><H3>getFileExtension</H3><PRE>public java.lang.String <B>getFileExtension</B>() throws java.lang.Exception</PRE><DL><DD>Gets the file extension<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>a string conatining the file extension (including the '.')<DT><B>Throws:</B><DD><CODE>java.lang.Exception</CODE> - exception if a Saver not implementing FileSourcedConverter is used.</DL></DD></DL><HR><A NAME="setFile(java.io.File)"><!-- --></A><H3>setFile</H3><PRE>public void <B>setFile</B>(java.io.File file) throws java.io.IOException</PRE><DL><DD>Sets the output file<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>file</CODE> - the output file<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - exception if new output file cannot be set</DL></DD></DL><HR><A NAME="setFilePrefix(java.lang.String)"><!-- --></A><H3>setFilePrefix</H3><PRE>public void <B>setFilePrefix</B>(java.lang.String prefix) throws java.lang.Exception</PRE><DL><DD>Sets the file prefix. This method is used in the KnowledgeFlow GUI.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>prefix</CODE> - the prefix of the file name<DT><B>Throws:</B><DD><CODE>java.lang.Exception</CODE> - exception if a Saver not implementing FileSourcedConverter is used.</DL></DD></DL><HR><A NAME="filePrefix()"><!-- --></A><H3>filePrefix</H3><PRE>public java.lang.String <B>filePrefix</B>() throws java.lang.Exception</PRE><DL><DD>Gets the file prefix This method is used in the KnowledgeFlow GUI.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>the prefix of the file name<DT><B>Throws:</B><DD><CODE>java.lang.Exception</CODE> - exception if a Saver not implementing FileSourcedConverter is used.</DL></DD></DL><HR><A NAME="setDir(java.lang.String)"><!-- --></A><H3>setDir</H3><PRE>public void <B>setDir</B>(java.lang.String dir) throws java.io.IOException</PRE><DL><DD>Sets the directory of the output file. This method is used in the KnowledgeFlow GUI.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>dir</CODE> - a string containing the path and name of the directory<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - exception if a Saver not implementing FileSourcedConverter is used.</DL></DD></DL><HR><A NAME="setDirAndPrefix(java.lang.String, java.lang.String)"><!-- --></A><H3>setDirAndPrefix</H3><PRE>public void <B>setDirAndPrefix</B>(java.lang.String relationName, java.lang.String add) throws java.io.IOException</PRE><DL><DD>Sets the file prefix and the directory. This method is used in the KnowledgeFlow GUI.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>relationName</CODE> - the name of the realtion to be saved<DD><CODE>add</CODE> - additional String for the file name<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - exception if a Saver not implementing FileSourcedConverter is used.</DL></DD></DL><HR><A NAME="retrieveDir()"><!-- --></A><H3>retrieveDir</H3><PRE>public java.lang.String <B>retrieveDir</B>() throws java.io.IOException</PRE><DL><DD>Gets the driectory of the output file This method is used in the KnowledgeFlow GUI.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>the directory as a string<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - exception if a Saver not implementing FileSourcedConverter is used.</DL></DD></DL><HR><A NAME="setInstances(weka.core.Instances)"><!-- --></A><H3>setInstances</H3><PRE>public void <B>setInstances</B>(<A HREF="../../../weka/core/Instances.html" title="class in weka.core">Instances</A> instances)</PRE><DL><DD>Sets the instances to be saved<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>instances</CODE> - the instances</DL></DD></DL><HR><A NAME="writeBatch()"><!-- --></A><H3>writeBatch</H3><PRE>public void <B>writeBatch</B>() throws java.io.IOException</PRE><DL><DD>Writes to a destination in batch mode<P><DD><DL></DL></DD><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - throws exection if writting in batch mode is not possible</DL></DD></DL><HR><A NAME="writeIncremental(weka.core.Instance)"><!-- --></A><H3>writeIncremental</H3><PRE>public void <B>writeIncremental</B>(<A HREF="../../../weka/core/Instance.html" title="class in weka.core">Instance</A> inst) throws java.io.IOException</PRE><DL><DD>Writes to a destination in incremental mode. If the instance is null, the outputfile will be closed.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>inst</CODE> - the instance to write, if null the output file is closed<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - throws exception if incremental writting is not possible</DL></DD></DL><HR><A NAME="getWriteMode()"><!-- --></A><H3>getWriteMode</H3><PRE>public int <B>getWriteMode</B>()</PRE><DL><DD>Gets the write mode<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>an integer representing the write mode</DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ======= START OF BOTTOM NAVBAR ====== --><A NAME="navbar_bottom"><!-- --></A><A HREF="#skip-navbar_bottom" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../Tutorial.pdf"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="http://www.cs.waikato.ac.nz/ml/weka/index.html"><FONT CLASS="NavBarFont1"><B>Weka's home</B></FONT></A> </TD> </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../weka/core/converters/Loader.html" title="interface in weka.core.converters"><B>PREV CLASS</B></A> NEXT CLASS</FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../index.html" target="_top"><B>FRAMES</B></A> <A HREF="Saver.html" target="_top"><B>NO FRAMES</B></A> <SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--></SCRIPT><NOSCRIPT> <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | CONSTR | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: <A HREF="#field_detail">FIELD</A> | CONSTR | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_bottom"></A><!-- ======== END OF BOTTOM NAVBAR ======= --><HR></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -