libsbml.XMLToken.setNamespaces C# (CSharp) Method

setNamespaces() public method

public setNamespaces ( XMLNamespaces namespaces ) : int
namespaces XMLNamespaces
return int
        public int setNamespaces(XMLNamespaces namespaces)
        {
            int ret = libsbmlPINVOKE.XMLToken_setNamespaces(swigCPtr, XMLNamespaces.getCPtr(namespaces));
            if (libsbmlPINVOKE.SWIGPendingException.Pending) throw libsbmlPINVOKE.SWIGPendingException.Retrieve();
            return ret;
        }

Usage Example

コード例 #1
0
 public void test_XMLToken_newSetters_setNamespaces1()
 {
     XMLTriple triple = new  XMLTriple("test","","");
       XMLAttributes attr = new  XMLAttributes();
       XMLToken token = new  XMLToken(triple,attr);
       XMLNamespaces ns = new  XMLNamespaces();
       assertTrue( token.getNamespacesLength() == 0 );
       assertTrue( token.isNamespacesEmpty() == true );
       ns.add( "http://test1.org/", "test1");
       int i = token.setNamespaces(ns);
       assertTrue( i == libsbml.LIBSBML_OPERATION_SUCCESS );
       assertTrue( token.getNamespacesLength() == 1 );
       assertTrue( token.isNamespacesEmpty() == false );
       attr = null;
       triple = null;
       token = null;
       ns = null;
 }
All Usage Examples Of libsbml.XMLToken::setNamespaces