ClickHouse/base/poco/XML/src/LocatorImpl.cpp
Robert Schulze b79ead9c84
Move poco to base/poco/ (#46075)
* Replicate poco into base/poco/

* De-register poco submodule

* Build poco from ClickHouse

* Exclude poco from stylecheck

* Exclude poco from whitespace check

* Exclude poco from typo check

* Remove x bit from sources/headers (the style check complained)

* Exclude poco from duplicate include check

* Fix fasttest

* Remove contrib/poco-cmake/*

* Simplify poco build descriptions

* Remove poco stuff not used by ClickHouse

* Glob poco sources

* Exclude poco from clang-tidy
2023-02-08 12:04:11 +01:00

105 lines
1.5 KiB
C++

//
// LocatorImpl.cpp
//
// Library: XML
// Package: SAX
// Module: SAX
//
// Copyright (c) 2004-2006, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// SPDX-License-Identifier: BSL-1.0
//
#include "Poco/SAX/LocatorImpl.h"
namespace Poco {
namespace XML {
LocatorImpl::LocatorImpl()
{
_lineNumber = 0;
_columnNumber = 0;
}
LocatorImpl::LocatorImpl(const Locator& loc)
{
_publicId = loc.getPublicId();
_systemId = loc.getSystemId();
_lineNumber = loc.getLineNumber();
_columnNumber = loc.getColumnNumber();
}
LocatorImpl::~LocatorImpl()
{
}
LocatorImpl& LocatorImpl::operator = (const Locator& loc)
{
if (&loc != this)
{
_publicId = loc.getPublicId();
_systemId = loc.getSystemId();
_lineNumber = loc.getLineNumber();
_columnNumber = loc.getColumnNumber();
}
return *this;
}
XMLString LocatorImpl::getPublicId() const
{
return _publicId;
}
XMLString LocatorImpl::getSystemId() const
{
return _systemId;
}
int LocatorImpl::getLineNumber() const
{
return _lineNumber;
}
int LocatorImpl::getColumnNumber() const
{
return _columnNumber;
}
void LocatorImpl::setPublicId(const XMLString& publicId)
{
_publicId = publicId;
}
void LocatorImpl::setSystemId(const XMLString& systemId)
{
_systemId = systemId;
}
void LocatorImpl::setLineNumber(int lineNumber)
{
_lineNumber = lineNumber;
}
void LocatorImpl::setColumnNumber(int columnNumber)
{
_columnNumber = columnNumber;
}
} } // namespace Poco::XML