You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xalan.apache.org by db...@locus.apache.org on 2000/08/08 18:29:07 UTC

cvs commit: xml-xalan/c/src/XSLT XSLTEngineImpl.cpp XSLTInputSource.cpp XSLTInputSource.hpp

dbertoni    00/08/08 09:29:07

  Modified:    c/src/XSLT XSLTEngineImpl.cpp XSLTInputSource.cpp
                        XSLTInputSource.hpp
  Log:
  Fixes so that XSLTInputSource and a standard istream will work for a stylesheet.
  
  Revision  Changes    Path
  1.54      +1 -3      xml-xalan/c/src/XSLT/XSLTEngineImpl.cpp
  
  Index: XSLTEngineImpl.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/src/XSLT/XSLTEngineImpl.cpp,v
  retrieving revision 1.53
  retrieving revision 1.54
  diff -u -r1.53 -r1.54
  --- XSLTEngineImpl.cpp	2000/08/01 19:43:27	1.53
  +++ XSLTEngineImpl.cpp	2000/08/08 16:29:06	1.54
  @@ -543,7 +543,7 @@
   	const XalanDOMChar* const	systemID = stylesheetSource.getSystemId();
   	XalanNode* const			stylesheetNode = stylesheetSource.getNode();
   
  -	if (systemID != 0 || stylesheetNode != 0)
  +	if (systemID != 0 || stylesheetNode != 0 || stylesheetSource.getStream() != 0)
   	{
   		XalanDOMString	xslIdentifier;
   
  @@ -563,8 +563,6 @@
   			}
   			else
   			{
  -				assert(systemID != 0);
  -
   				xslIdentifier = systemID;
   
   				diag(XALAN_STATIC_UCODE_STRING("========= Parsing ") + xslIdentifier + XALAN_STATIC_UCODE_STRING(" =========="));
  
  
  
  1.10      +2 -18     xml-xalan/c/src/XSLT/XSLTInputSource.cpp
  
  Index: XSLTInputSource.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/src/XSLT/XSLTInputSource.cpp,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- XSLTInputSource.cpp	2000/07/19 18:47:39	1.9
  +++ XSLTInputSource.cpp	2000/08/08 16:29:07	1.10
  @@ -129,7 +129,7 @@
   
   
   XSLTInputSource::XSLTInputSource(XalanNode*		node) :
  -	InputSource(""),
  +	InputSource(),
   	m_stream(0),
   	m_node(node)
   {
  @@ -142,7 +142,7 @@
   #else
   XSLTInputSource::XSLTInputSource(std::istream*	stream) :
   #endif
  -	InputSource(""),
  +	InputSource(),
   	m_stream(stream),
   	m_node(0)
   {
  @@ -167,20 +167,4 @@
   	}
   
   	return theResult;
  -}
  -
  -
  -
  -void
  -XSLTInputSource::setNode(XalanNode*		node)
  -{
  -	m_node = node;
  -}
  -
  -
  -
  -XalanNode*
  -XSLTInputSource::getNode() const
  -{
  -	return m_node;
   }
  
  
  
  1.8       +28 -2     xml-xalan/c/src/XSLT/XSLTInputSource.hpp
  
  Index: XSLTInputSource.hpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/src/XSLT/XSLTInputSource.hpp,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- XSLTInputSource.hpp	2000/05/31 17:01:19	1.7
  +++ XSLTInputSource.hpp	2000/08/08 16:29:07	1.8
  @@ -188,7 +188,10 @@
   	 * @param node DOM node that is root of the document
   	 */
   	void
  -	setNode(XalanNode*	node);
  +	setNode(XalanNode*	node)
  +	{
  +		m_node = node;
  +	}
   
   	/**
   	 * Retrieve the DOM node for this input source.
  @@ -196,7 +199,30 @@
   	 * @return DOM node that is root of the document
   	 */
   	XalanNode*
  -	getNode() const;
  +	getNode() const
  +	{
  +		return m_node;
  +	}
  +
  +#if defined(XALAN_NO_NAMESPACES)
  +	istream*
  +#else
  +	std::istream*
  +#endif
  +	getStream() const
  +	{
  +		return m_stream;
  +	}
  +
  +	void
  +#if defined(XALAN_NO_NAMESPACES)
  +	setStream(istream*	stream)
  +#else
  +	setStream(std::istream*	stream)
  +#endif
  +	{
  +		m_stream = stream;
  +	}
   
   private: