Inheritance: IDisposable
 /**
    * Creates a new XMLOutputStream that wraps stream.
    *
    * @if notcpp @htmlinclude warn-default-args-in-docs.html @endif
    */
 public XMLOutputStream(OStream stream, string encoding, bool writeXMLDecl)
     : this(libsbmlPINVOKE.new_XMLOutputStream__SWIG_2(SWIGTYPE_p_std__ostream.getCPtr(stream.get_ostream()), encoding, writeXMLDecl), true)
 {
     if (libsbmlPINVOKE.SWIGPendingException.Pending) throw libsbmlPINVOKE.SWIGPendingException.Retrieve();
 }
 /**
    * Creates a new XMLOutputStream that wraps stream.
    *
    * @if notcpp @htmlinclude warn-default-args-in-docs.html @endif
    */
 public XMLOutputStream(OStream stream)
     : this(libsbmlPINVOKE.new_XMLOutputStream__SWIG_4(SWIGTYPE_p_std__ostream.getCPtr(stream.get_ostream())), true)
 {
     if (libsbmlPINVOKE.SWIGPendingException.Pending) throw libsbmlPINVOKE.SWIGPendingException.Retrieve();
 }
 /**
    * Prints to the given output stream all the errors or warnings
    * encountered during parsing, consistency checking, or attempted
    * translation of this model.
    *
    * If no errors have occurred, i.e., <c>getNumErrors() == 0</c>, no
    * output will be sent to the stream.
    *
    * The format of the output is:
    * <code>
    N error(s):
  line NNN: (id) message
  </code>
    *
    * @if notcpp @docnote @htmlinclude warn-default-args-in-docs.html @endif
    */
 public void printErrors(OStream stream)
 {
     libsbmlPINVOKE.SBMLDocument_printErrors__SWIG_0(swigCPtr, SWIGTYPE_p_std__ostream.getCPtr(stream.get_ostream()));
     if (libsbmlPINVOKE.SWIGPendingException.Pending) throw libsbmlPINVOKE.SWIGPendingException.Retrieve();
 }
Beispiel #4
0
        internal static HandleRef getCPtrAndDisown(OStream obj)
        {
            HandleRef ptr = new HandleRef(null, IntPtr.Zero);

            if (obj != null)
            {
            ptr             = obj.swigCPtr;
            obj.swigCMemOwn = false;
            }

            return ptr;
        }
Beispiel #5
0
 internal static HandleRef getCPtr(OStream obj)
 {
     return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
 }
Beispiel #6
0
 /**
    * Writes the given SBML document to the output stream.
    *
    * @param d the SBML document to be written
    *
    * @param stream the stream object where the SBML is to be written.
    *
    * @return @c true on success and @c false if one of the underlying
    * parser components fail (rare).
    *
    * @see setProgramVersion(string version)
    * @see setProgramName(string name)
    */
 public bool writeSBML(SBMLDocument d, OStream stream)
 {
     bool ret = libsbmlPINVOKE.SBMLWriter_writeSBML__SWIG_1(swigCPtr, SBMLDocument.getCPtr(d), SWIGTYPE_p_std__ostream.getCPtr(stream.get_ostream()));
     if (libsbmlPINVOKE.SWIGPendingException.Pending) throw libsbmlPINVOKE.SWIGPendingException.Retrieve();
     return ret;
 }
 /**
    * Prints the errors or warnings with given severity stored in this error log.
    *
    * This method prints the text to the stream given by the optional
    * parameter @p stream.  If no stream is given, the method prints the
    * output to the standard error stream.
    *
    * The format of the output is:
    * @verbatim
    N error(s):
  line NNN: (id) message
 @endverbatim
    * If no errors with that severity was found, then no output will be produced.
    *
    * @param stream the ostream or ostringstream object indicating where
    * the output should be printed.
    * @param severity the severity of the errors sought.
    *
    */
 public void printErrors(OStream stream, long severity)
 {
     libsbmlPINVOKE.XMLErrorLog_printErrors__SWIG_2(swigCPtr, SWIGTYPE_p_std__ostream.getCPtr(stream.get_ostream()), severity);
     if (libsbmlPINVOKE.SWIGPendingException.Pending) throw libsbmlPINVOKE.SWIGPendingException.Retrieve();
 }