diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:53:50 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:53:50 +0000 |
commit | 7be55ffa061c026e35e2d6a0effe1161ddb0d41f (patch) | |
tree | 8474f9b444b2756228600050f07a7ff25de532b2 /kode/kwsdl/parser.cpp | |
parent | f587f20a6d09f1729dd0a8c1cd8ee0110aec7451 (diff) | |
download | tdepim-7be55ffa061c026e35e2d6a0effe1161ddb0d41f.tar.gz tdepim-7be55ffa061c026e35e2d6a0effe1161ddb0d41f.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1157655 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kode/kwsdl/parser.cpp')
-rw-r--r-- | kode/kwsdl/parser.cpp | 62 |
1 files changed, 31 insertions, 31 deletions
diff --git a/kode/kwsdl/parser.cpp b/kode/kwsdl/parser.cpp index ab168b579..49f77eca4 100644 --- a/kode/kwsdl/parser.cpp +++ b/kode/kwsdl/parser.cpp @@ -19,13 +19,13 @@ Boston, MA 02110-1301, USA. */ -#include <qdom.h> +#include <tqdom.h> #include "parser.h" using namespace KWSDL; -static QString sns( const QString &str ) +static TQString sns( const TQString &str ) { int pos = str.find( ':' ); if ( pos != -1 ) @@ -59,18 +59,18 @@ void Parser::reset() mParser.clear(); } -void Parser::setSchemaBaseUrl( const QString &url ) +void Parser::setSchemaBaseUrl( const TQString &url ) { mParser.setSchemaBaseUrl( url ); } -void Parser::parse( const QDomElement &root ) +void Parser::parse( const TQDomElement &root ) { reset(); - QDomNode node = root.firstChild(); + TQDomNode node = root.firstChild(); while ( !node.isNull() ) { - QDomElement element = node.toElement(); + TQDomElement element = node.toElement(); if ( !element.isNull() ) { if ( element.tagName() == "types" ) parseTypes( element ); @@ -94,11 +94,11 @@ void Parser::parse( const QDomElement &root ) } } -void Parser::parseTypes( const QDomElement &parent ) +void Parser::parseTypes( const TQDomElement &parent ) { - QDomNode node = parent.firstChild(); + TQDomNode node = parent.firstChild(); while ( !node.isNull() ) { - QDomElement element = node.toElement(); + TQDomElement element = node.toElement(); if ( !element.isNull() ) { if ( element.tagName() == "schema" ) mParser.parseSchemaTag( element ); @@ -108,16 +108,16 @@ void Parser::parseTypes( const QDomElement &parent ) } } -void Parser::parseMessage( const QDomElement &parent, Message &message ) +void Parser::parseMessage( const TQDomElement &parent, Message &message ) { - QDomNode node = parent.firstChild(); + TQDomNode node = parent.firstChild(); while ( !node.isNull() ) { - QDomElement element = node.toElement(); + TQDomElement element = node.toElement(); if ( !element.isNull() ) { if ( element.tagName() == "part" ) { // HACK(groupwise): is element valid here as attribute? - QString type = sns( element.attribute( "type" ) ); + TQString type = sns( element.attribute( "type" ) ); if ( type.isEmpty() ) type = sns( element.attribute( "element" ) ); @@ -130,18 +130,18 @@ void Parser::parseMessage( const QDomElement &parent, Message &message ) } } -void Parser::parsePortType( const QDomElement &parent, Port &port ) +void Parser::parsePortType( const TQDomElement &parent, Port &port ) { - QDomNode node = parent.firstChild(); + TQDomNode node = parent.firstChild(); while ( !node.isNull() ) { - QDomElement element = node.toElement(); + TQDomElement element = node.toElement(); if ( !element.isNull() ) { if ( element.tagName() == "operation" ) { - QString input, output; + TQString input, output; - QDomNode childNode = element.firstChild(); + TQDomNode childNode = element.firstChild(); while ( !childNode.isNull() ) { - QDomElement childElement = childNode.toElement(); + TQDomElement childElement = childNode.toElement(); if ( !childElement.isNull() ) { if ( childElement.tagName() == "input" ) input = sns( childElement.attribute( "message" ) ); @@ -161,13 +161,13 @@ void Parser::parsePortType( const QDomElement &parent, Port &port ) } } -void Parser::parseBinding( const QDomElement &parent ) +void Parser::parseBinding( const TQDomElement &parent ) { Binding binding( sns( parent.attribute( "name" ) ), sns( parent.attribute( "type" ) ) ); - QDomNode node = parent.firstChild(); + TQDomNode node = parent.firstChild(); while ( !node.isNull() ) { - QDomElement element = node.toElement(); + TQDomElement element = node.toElement(); if ( !element.isNull() ) { if ( element.tagName() == "binding" ) { binding.setStyle( element.attribute( "style" ) ); @@ -176,14 +176,14 @@ void Parser::parseBinding( const QDomElement &parent ) Binding::Operation operation; operation.setName( element.attribute( "name" ) ); - QDomNode opNode = element.firstChild(); + TQDomNode opNode = element.firstChild(); while ( !opNode.isNull() ) { - QDomElement opElement = opNode.toElement(); + TQDomElement opElement = opNode.toElement(); if ( !opElement.isNull() ) { if ( opElement.tagName() == "operation" ) operation.setAction( opElement.attribute( "soapAction" ) ); else if ( opElement.tagName() == "input" ) { - QDomElement inputElement = opElement.firstChild().toElement(); + TQDomElement inputElement = opElement.firstChild().toElement(); Binding::Operation::Item input; input.setUse( inputElement.attribute( "use" ) ); @@ -192,7 +192,7 @@ void Parser::parseBinding( const QDomElement &parent ) operation.setInput( input ); } else if ( opElement.tagName() == "output" ) { - QDomElement outputElement = opElement.firstChild().toElement(); + TQDomElement outputElement = opElement.firstChild().toElement(); Binding::Operation::Item output; output.setUse( outputElement.attribute( "use" ) ); @@ -216,19 +216,19 @@ void Parser::parseBinding( const QDomElement &parent ) mBindings.append( binding ); } -void Parser::parseService( const QDomElement &parent ) +void Parser::parseService( const TQDomElement &parent ) { - QDomNode node = parent.firstChild(); + TQDomNode node = parent.firstChild(); while ( !node.isNull() ) { - QDomElement element = node.toElement(); + TQDomElement element = node.toElement(); if ( !element.isNull() ) { if ( element.tagName() == "port" ) { Service::Port port; port.mName = sns( element.attribute( "name" ) ); port.mBinding = sns( element.attribute( "binding" ) ); - QDomNode childNode = element.firstChild(); + TQDomNode childNode = element.firstChild(); if ( !childNode.isNull() ) { - QDomElement childElement = childNode.toElement(); + TQDomElement childElement = childNode.toElement(); port.mLocation = childElement.attribute( "location" ); } mService.addPort( port ); |