summaryrefslogtreecommitdiff
path: root/forms
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-06-30 14:35:23 +0200
committerNoel Grandin <noelgrandin@gmail.com>2015-07-06 06:14:15 +0000
commit89c77994d4638c86635c70535fab6508e2f3d900 (patch)
tree6a48a4f188e8f163c803d6af90cc4eb32ffdbf67 /forms
parent64385c7555c6bbb089f3ab8b2a5b623cadd6ee7d (diff)
remove some unnecessary typedefs around uno::Reference
Not very useful these days, since we have the css:: prefix to reduce verbosity. Found with a search like: git grep -nP 'typedef .*uno::Reference.*<.*>\s+\w+;' | grep -v 'std::' Change-Id: I16f41c53837ec5c613545ae45df38b0daddcbadd Reviewed-on: https://gerrit.libreoffice.org/16730 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'forms')
-rw-r--r--forms/source/xforms/binding.cxx94
-rw-r--r--forms/source/xforms/binding.hxx225
-rw-r--r--forms/source/xforms/collection.hxx124
-rw-r--r--forms/source/xforms/model.cxx36
-rw-r--r--forms/source/xforms/model.hxx183
-rw-r--r--forms/source/xforms/model_helper.hxx4
-rw-r--r--forms/source/xforms/model_ui.cxx8
-rw-r--r--forms/source/xforms/namedcollection.hxx20
-rw-r--r--forms/source/xforms/xformsevent.cxx8
-rw-r--r--forms/source/xforms/xformsevent.hxx35
10 files changed, 330 insertions, 407 deletions
diff --git a/forms/source/xforms/binding.cxx b/forms/source/xforms/binding.cxx
index face92b23c89..5c86447281b2 100644
--- a/forms/source/xforms/binding.cxx
+++ b/forms/source/xforms/binding.cxx
@@ -140,14 +140,14 @@ Binding::~Binding()
_setModel(NULL);
}
-void Binding::_setModel( const Model_t& xModel )
+void Binding::_setModel( const css::uno::Reference<css::xforms::XModel>& xModel )
{
PropertyChangeNotifier aNotifyModelChange( *this, HANDLE_Model );
PropertyChangeNotifier aNotifyModelIDChange( *this, HANDLE_ModelID );
// prepare binding for removal of old model
clear(); // remove all cached data (e.g. XPath evaluation results)
- XNameContainer_t xNamespaces = getModelNamespaces(); // save namespaces
+ css::uno::Reference<css::container::XNameContainer> xNamespaces = getModelNamespaces(); // save namespaces
mxModel = xModel;
@@ -166,7 +166,7 @@ OUString Binding::getModelID() const
}
-Binding::XNodeList_t Binding::getXNodeList()
+css::uno::Reference<css::xml::dom::XNodeList> Binding::getXNodeList()
{
// first make sure we are bound
if( ! maBindingExpression.hasValue() )
@@ -314,7 +314,7 @@ EvaluationContext Binding::getEvaluationContext() const
}
-Binding::IntSequence_t Binding::getUnoTunnelID()
+css::uno::Sequence<sal_Int8> Binding::getUnoTunnelID()
{
static cppu::OImplementationId aImplementationId;
return aImplementationId.getImplementationId();
@@ -416,17 +416,17 @@ void Binding::setType( const OUString& sTypeName )
bindingModified();
}
-void Binding::setBindingNamespaces( const XNameContainer_t& rNamespaces )
+void Binding::setBindingNamespaces( const css::uno::Reference<css::container::XNameContainer>& rNamespaces )
{
_setNamespaces( rNamespaces, true );
}
-Binding::XNameContainer_t Binding::getModelNamespaces() const
+css::uno::Reference<css::container::XNameContainer> Binding::getModelNamespaces() const
{
return _getNamespaces();
}
-void Binding::setModelNamespaces( const XNameContainer_t& rNamespaces )
+void Binding::setModelNamespaces( const css::uno::Reference<css::container::XNameContainer>& rNamespaces )
{
_setNamespaces( rNamespaces, false );
}
@@ -486,7 +486,7 @@ Model* Binding::getModelImpl() const
return getModelImpl( mxModel );
}
-Model* Binding::getModelImpl( const Model_t& xModel )
+Model* Binding::getModelImpl( const css::uno::Reference<css::xforms::XModel>& xModel )
{
Reference<XUnoTunnel> xTunnel( xModel, UNO_QUERY );
Model* pModel = xTunnel.is()
@@ -599,7 +599,7 @@ void Binding::bind( bool bForceRebind )
// 2) register suitable listeners on the instance (and remove old ones)
if( maEventNodes.empty() || bForceRebind )
{
- for( XNodes_t::iterator aIter = maEventNodes.begin();
+ for( auto aIter = maEventNodes.begin();
aIter != maEventNodes.end();
++aIter )
lcl_removeListenerFromNode( *aIter, this );
@@ -660,7 +660,7 @@ void Binding::bind( bool bForceRebind )
// helper for Binding::valueModified
-static void lcl_modified( const Binding::XModifyListener_t& xListener,
+static void lcl_modified( const css::uno::Reference<css::util::XModifyListener>& xListener,
const Reference<XInterface>& xSource )
{
OSL_ENSURE( xListener.is(), "no listener?" );
@@ -668,7 +668,7 @@ static void lcl_modified( const Binding::XModifyListener_t& xListener,
}
// helper for Binding::valueModified
-static void lcl_listentry( const Binding::XListEntryListener_t& xListener,
+static void lcl_listentry( const css::uno::Reference<css::form::binding::XListEntryListener>& xListener,
const Reference<XInterface>& xSource )
{
OSL_ENSURE( xListener.is(), "no listener?" );
@@ -677,7 +677,7 @@ static void lcl_listentry( const Binding::XListEntryListener_t& xListener,
}
// helper for Binding::valueModified
-static void lcl_validate( const Binding::XValidityConstraintListener_t& xListener,
+static void lcl_validate( const css::uno::Reference<css::form::validation::XValidityConstraintListener>& xListener,
const Reference<XInterface>& xSource )
{
OSL_ENSURE( xListener.is(), "no listener?" );
@@ -725,7 +725,7 @@ void Binding::valueModified()
distributeMIP( xNode->getFirstChild() );
}
-void Binding::distributeMIP( const XNode_t & rxNode ) {
+void Binding::distributeMIP( const css::uno::Reference<css::xml::dom::XNode> & rxNode ) {
typedef com::sun::star::xforms::XFormsEventConcrete XFormsEvent_t;
OUString sEventName("xforms-generic");
@@ -734,12 +734,12 @@ void Binding::distributeMIP( const XNode_t & rxNode ) {
Reference<XEvent> xEvent(pEvent);
// naive depth-first traversal
- XNode_t xNode( rxNode );
+ css::uno::Reference<css::xml::dom::XNode> xNode( rxNode );
while(xNode.is()) {
// notifications should be triggered at the
// leaf nodes first, bubbling upwards the hierarchy.
- XNode_t child(xNode->getFirstChild());
+ css::uno::Reference<css::xml::dom::XNode> child(xNode->getFirstChild());
if(child.is())
distributeMIP(child);
@@ -799,7 +799,7 @@ MIP Binding::getLocalMIP() const
return aMIP;
}
-Binding::XDataType_t Binding::getDataType()
+css::uno::Reference<css::xsd::XDataType> Binding::getDataType()
{
OSL_ENSURE( getModel().is(), "need model" );
OSL_ENSURE( getModel()->getDataTypeRepository().is(), "need types" );
@@ -836,7 +836,7 @@ void Binding::clear()
pModel->removeMIPs( this );
// remove all references
- for( XNodes_t::iterator aIter = maEventNodes.begin();
+ for( auto aIter = maEventNodes.begin();
aIter != maEventNodes.end();
++aIter )
lcl_removeListenerFromNode( *aIter, this );
@@ -854,8 +854,8 @@ void Binding::clear()
}
-static void lcl_removeOtherNamespaces( const Binding::XNameContainer_t& xFrom,
- Binding::XNameContainer_t& xTo )
+static void lcl_removeOtherNamespaces( const css::uno::Reference<css::container::XNameContainer>& xFrom,
+ css::uno::Reference<css::container::XNameContainer>& xTo )
{
OSL_ENSURE( xFrom.is(), "no source" );
OSL_ENSURE( xTo.is(), "no target" );
@@ -881,8 +881,8 @@ static void lcl_removeOtherNamespaces( const Binding::XNameContainer_t& xFrom,
* @param bFromSource true: use elements from source
* false: use only elements from target
*/
-static void lcl_copyNamespaces( const Binding::XNameContainer_t& xFrom,
- Binding::XNameContainer_t& xTo,
+static void lcl_copyNamespaces( const css::uno::Reference<css::container::XNameContainer>& xFrom,
+ css::uno::Reference<css::container::XNameContainer>& xTo,
bool bOverwrite )
{
OSL_ENSURE( xFrom.is(), "no source" );
@@ -918,9 +918,9 @@ static void lcl_copyNamespaces( const Binding::XNameContainer_t& xFrom,
// implement get*Namespaces()
// (identical for both variants)
-Binding::XNameContainer_t Binding::_getNamespaces() const
+css::uno::Reference<css::container::XNameContainer> Binding::_getNamespaces() const
{
- XNameContainer_t xNamespaces = new NameContainer<OUString>();
+ css::uno::Reference<css::container::XNameContainer> xNamespaces = new NameContainer<OUString>();
lcl_copyNamespaces( mxNamespaces, xNamespaces, true );
// merge model's with binding's own namespaces
@@ -933,11 +933,11 @@ Binding::XNameContainer_t Binding::_getNamespaces() const
// implement set*Namespaces()
// bBinding = true: setBindingNamespaces, otherwise: setModelNamespaces
-void Binding::_setNamespaces( const XNameContainer_t& rNamespaces,
+void Binding::_setNamespaces( const css::uno::Reference<css::container::XNameContainer>& rNamespaces,
bool bBinding )
{
Model* pModel = getModelImpl();
- XNameContainer_t xModelNamespaces = ( pModel != NULL )
+ css::uno::Reference<css::container::XNameContainer> xModelNamespaces = ( pModel != NULL )
? pModel->getNamespaces()
: NULL;
OSL_ENSURE( ( pModel != NULL ) == xModelNamespaces.is(), "no model nmsp?");
@@ -966,7 +966,7 @@ void Binding::_setNamespaces( const XNameContainer_t& rNamespaces,
&& xModelNamespaces->hasByName( rName ) );
// write namespace into the appropriate namespace container
- XNameContainer_t& rWhich = bLocal ? mxNamespaces : xModelNamespaces;
+ css::uno::Reference<css::container::XNameContainer>& rWhich = bLocal ? mxNamespaces : xModelNamespaces;
OSL_ENSURE( rWhich.is(), "whoops" );
if( rWhich->hasByName( rName ) )
rWhich->replaceByName( rName, aValue );
@@ -1016,19 +1016,19 @@ void Binding::_checkBindingID()
// XValueBinding
-Binding::Sequence_Type_t Binding::getSupportedValueTypes()
+css::uno::Sequence<css::uno::Type> Binding::getSupportedValueTypes()
throw( RuntimeException, std::exception )
{
return Convert::get().getTypes();
}
-sal_Bool Binding::supportsType( const Type_t& rType )
+sal_Bool Binding::supportsType( const css::uno::Type& rType )
throw( RuntimeException, std::exception )
{
return Convert::get().hasType( rType );
}
-Binding::Any_t Binding::getValue( const Type_t& rType )
+css::uno::Any Binding::getValue( const css::uno::Type& rType )
throw( IncompatibleTypesException,
RuntimeException, std::exception )
{
@@ -1040,7 +1040,7 @@ Binding::Any_t Binding::getValue( const Type_t& rType )
throw IncompatibleTypesException( EXCEPT( "type unsupported" ) );
// return string value (if present; else return empty Any)
- Binding::Any_t result = Any();
+ css::uno::Any result;
if(maBindingExpression.hasValue()) {
OUString pathExpr(maBindingExpression.getString());
Convert &rConvert = Convert::get();
@@ -1050,7 +1050,7 @@ Binding::Any_t Binding::getValue( const Type_t& rType )
return result;
}
-void Binding::setValue( const Any_t& aValue )
+void Binding::setValue( const css::uno::Any& aValue )
throw( IncompatibleTypesException,
InvalidBindingStateException,
NoSupportException,
@@ -1065,7 +1065,7 @@ void Binding::setValue( const Any_t& aValue )
if( maBindingExpression.hasValue() )
{
- Binding::XNode_t xNode = maBindingExpression.getNode();
+ css::uno::Reference<css::xml::dom::XNode> xNode = maBindingExpression.getNode();
if( xNode.is() )
{
OUString sValue = Convert::get().toXSD( aValue );
@@ -1152,7 +1152,7 @@ Sequence<OUString> Binding::getAllListEntries()
return aSequence;
}
-void Binding::addListEntryListener( const XListEntryListener_t& xListener )
+void Binding::addListEntryListener( const css::uno::Reference<css::form::binding::XListEntryListener>& xListener )
throw( NullPointerException,
RuntimeException, std::exception )
{
@@ -1164,7 +1164,7 @@ void Binding::addListEntryListener( const XListEntryListener_t& xListener )
maListEntryListeners.push_back( xListener );
}
-void Binding::removeListEntryListener( const XListEntryListener_t& xListener )
+void Binding::removeListEntryListener( const css::uno::Reference<css::form::binding::XListEntryListener>& xListener )
throw( NullPointerException,
RuntimeException, std::exception )
{
@@ -1180,7 +1180,7 @@ void Binding::removeListEntryListener( const XListEntryListener_t& xListener )
// XValidator
-sal_Bool Binding::isValid( const Any_t& )
+sal_Bool Binding::isValid( const css::uno::Any& )
throw( RuntimeException, std::exception )
{
// first, check for model
@@ -1191,7 +1191,7 @@ sal_Bool Binding::isValid( const Any_t& )
}
OUString Binding::explainInvalid(
- const Any_t& /*Value*/ )
+ const css::uno::Any& /*Value*/ )
throw( RuntimeException, std::exception )
{
// first, check for model
@@ -1202,7 +1202,7 @@ OUString Binding::explainInvalid(
}
void Binding::addValidityConstraintListener(
- const XValidityConstraintListener_t& xListener )
+ const css::uno::Reference<css::form::validation::XValidityConstraintListener>& xListener )
throw( NullPointerException,
RuntimeException, std::exception )
{
@@ -1213,7 +1213,7 @@ void Binding::addValidityConstraintListener(
}
void Binding::removeValidityConstraintListener(
- const XValidityConstraintListener_t& xListener )
+ const css::uno::Reference<css::form::validation::XValidityConstraintListener>& xListener )
throw( NullPointerException,
RuntimeException, std::exception )
{
@@ -1230,7 +1230,7 @@ void Binding::removeValidityConstraintListener(
// xml::dom::event::XEventListener
-void Binding::handleEvent( const XEvent_t& xEvent )
+void Binding::handleEvent( const css::uno::Reference<css::xml::dom::events::XEvent>& xEvent )
throw( RuntimeException, std::exception )
{
OUString sType(xEvent->getType());
@@ -1263,7 +1263,7 @@ void Binding::handleEvent( const XEvent_t& xEvent )
// lang::XUnoTunnel
-sal_Int64 Binding::getSomething( const IntSequence_t& xId )
+sal_Int64 Binding::getSomething( const css::uno::Sequence<sal_Int8>& xId )
throw( RuntimeException, std::exception )
{
return reinterpret_cast<sal_Int64>( ( xId == getUnoTunnelID() ) ? this : NULL );
@@ -1273,7 +1273,7 @@ sal_Int64 Binding::getSomething( const IntSequence_t& xId )
// XCloneable
-Binding::XCloneable_t SAL_CALL Binding::createClone()
+css::uno::Reference<css::util::XCloneable> SAL_CALL Binding::createClone()
throw( RuntimeException, std::exception )
{
Reference< XPropertySet > xClone;
@@ -1286,7 +1286,7 @@ Binding::XCloneable_t SAL_CALL Binding::createClone()
xClone = new Binding;
copy( this, xClone );
}
- return XCloneable_t( xClone, UNO_QUERY );
+ return css::uno::Reference<css::util::XCloneable>( xClone, UNO_QUERY );
}
@@ -1309,9 +1309,9 @@ void Binding::initializePropertySet()
{
REGISTER_PROPERTY ( BindingID, OUString );
REGISTER_PROPERTY ( BindingExpression, OUString );
- REGISTER_PROPERTY_RO ( Model, Model_t );
- REGISTER_PROPERTY ( BindingNamespaces, XNameContainer_t );
- REGISTER_PROPERTY ( ModelNamespaces, XNameContainer_t );
+ REGISTER_PROPERTY_RO ( Model, css::uno::Reference<css::xforms::XModel> );
+ REGISTER_PROPERTY ( BindingNamespaces, css::uno::Reference<css::container::XNameContainer> );
+ REGISTER_PROPERTY ( ModelNamespaces, css::uno::Reference<css::container::XNameContainer> );
REGISTER_PROPERTY_RO ( ModelID, OUString );
REGISTER_PROPERTY ( ReadonlyExpression, OUString );
REGISTER_PROPERTY ( RelevantExpression, OUString );
@@ -1329,7 +1329,7 @@ void Binding::initializePropertySet()
}
void Binding::addModifyListener(
- const XModifyListener_t& xListener )
+ const css::uno::Reference<css::util::XModifyListener>& xListener )
throw( RuntimeException, std::exception )
{
OSL_ENSURE( xListener.is(), "need listener!" );
@@ -1344,7 +1344,7 @@ void Binding::addModifyListener(
}
void Binding::removeModifyListener(
- const XModifyListener_t& xListener )
+ const css::uno::Reference<css::util::XModifyListener>& xListener )
throw( RuntimeException, std::exception )
{
ModifyListeners_t::iterator aIter =
diff --git a/forms/source/xforms/binding.hxx b/forms/source/xforms/binding.hxx
index ca07d0213880..b940f736de27 100644
--- a/forms/source/xforms/binding.hxx
+++ b/forms/source/xforms/binding.hxx
@@ -21,6 +21,22 @@
#define INCLUDED_FORMS_SOURCE_XFORMS_BINDING_HXX
#include <com/sun/star/uno/Reference.hxx>
+#include <cppuhelper/implbase8.hxx>
+#include <propertysetbase.hxx>
+#include <com/sun/star/form/binding/XValueBinding.hpp>
+#include <com/sun/star/form/binding/XListEntrySource.hpp>
+#include <com/sun/star/form/validation/XValidator.hpp>
+#include <com/sun/star/util/XModifyBroadcaster.hpp>
+#include <com/sun/star/container/XNamed.hpp>
+#include <com/sun/star/xml/dom/events/XEventListener.hpp>
+#include <com/sun/star/lang/XUnoTunnel.hpp>
+#include <com/sun/star/util/XCloneable.hpp>
+
+#include "pathexpression.hxx"
+#include "boolexpression.hxx"
+#include "mip.hxx"
+#include <rtl/ustring.hxx>
+#include <vector>
// forward declaractions
namespace xforms
@@ -42,23 +58,6 @@ namespace com { namespace sun { namespace star {
namespace xsd { class XDataType; }
} } }
-#include <cppuhelper/implbase8.hxx>
-#include <propertysetbase.hxx>
-#include <com/sun/star/form/binding/XValueBinding.hpp>
-#include <com/sun/star/form/binding/XListEntrySource.hpp>
-#include <com/sun/star/form/validation/XValidator.hpp>
-#include <com/sun/star/util/XModifyBroadcaster.hpp>
-#include <com/sun/star/container/XNamed.hpp>
-#include <com/sun/star/xml/dom/events/XEventListener.hpp>
-#include <com/sun/star/lang/XUnoTunnel.hpp>
-#include <com/sun/star/util/XCloneable.hpp>
-
-#include "pathexpression.hxx"
-#include "boolexpression.hxx"
-#include "mip.hxx"
-#include <rtl/ustring.hxx>
-#include <vector>
-
namespace xforms
@@ -76,41 +75,29 @@ namespace xforms
typedef cppu::ImplInheritanceHelper8<
PropertySetBase,
- com::sun::star::form::binding::XValueBinding,
- com::sun::star::form::binding::XListEntrySource,
- com::sun::star::form::validation::XValidator,
- com::sun::star::util::XModifyBroadcaster,
- com::sun::star::container::XNamed,
- com::sun::star::xml::dom::events::XEventListener,
- com::sun::star::lang::XUnoTunnel,
- com::sun::star::util::XCloneable
+ css::form::binding::XValueBinding,
+ css::form::binding::XListEntrySource,
+ css::form::validation::XValidator,
+ css::util::XModifyBroadcaster,
+ css::container::XNamed,
+ css::xml::dom::events::XEventListener,
+ css::lang::XUnoTunnel,
+ css::util::XCloneable
> Binding_t;
class Binding : public Binding_t
{
public:
- typedef com::sun::star::uno::Reference<com::sun::star::xforms::XModel> Model_t;
- typedef com::sun::star::uno::Reference<com::sun::star::util::XModifyListener> XModifyListener_t;
- typedef std::vector<XModifyListener_t> ModifyListeners_t;
- typedef com::sun::star::uno::Reference<com::sun::star::form::validation::XValidityConstraintListener> XValidityConstraintListener_t;
- typedef std::vector<XValidityConstraintListener_t> XValidityConstraintListeners_t;
- typedef com::sun::star::uno::Reference<com::sun::star::form::binding::XListEntryListener> XListEntryListener_t;
- typedef std::vector<XListEntryListener_t> XListEntryListeners_t;
- typedef com::sun::star::uno::Reference<com::sun::star::container::XNameContainer> XNameContainer_t;
- typedef com::sun::star::uno::Reference<com::sun::star::xml::dom::XNode> XNode_t;
- typedef com::sun::star::uno::Reference<com::sun::star::xml::dom::XNodeList> XNodeList_t;
- typedef com::sun::star::uno::Reference<com::sun::star::util::XCloneable> XCloneable_t;
- typedef com::sun::star::uno::Sequence<sal_Int8> IntSequence_t;
- typedef com::sun::star::uno::Sequence<OUString> StringSequence_t;
- typedef std::vector<MIP> MIPs_t;
- typedef std::vector<XNode_t> XNodes_t;
+ typedef std::vector<css::uno::Reference<css::util::XModifyListener> > ModifyListeners_t;
+ typedef std::vector<css::uno::Reference<css::form::validation::XValidityConstraintListener> > XValidityConstraintListeners_t;
+ typedef std::vector<css::uno::Reference<css::form::binding::XListEntryListener> > XListEntryListeners_t;
private:
/// the Model to which this Binding belongs; may be NULL
- Model_t mxModel;
+ css::uno::Reference<css::xforms::XModel> mxModel;
/// binding-ID. A document-wide unique ID for this binding element.
OUString msBindingID;
@@ -137,7 +124,7 @@ private:
ComputedExpression maCalculate;
/// the XML namespaces used for XML names/XPath-expressions in this binding
- XNameContainer_t mxNamespaces;
+ css::uno::Reference<css::container::XNameContainer> mxNamespaces;
/// a type name
OUString msTypeName;
@@ -152,7 +139,7 @@ private:
XValidityConstraintListeners_t maValidityListeners;
/// nodes on which we are listening for events
- XNodes_t maEventNodes;
+ std::vector<css::uno::Reference<css::xml::dom::XNode> > maEventNodes;
/// the current MIP object for the first node we are bound to
MIP maMIP;
@@ -178,8 +165,8 @@ public:
// property methods: get/set value
- Model_t getModel() const { return mxModel;} /// get XForms model
- void _setModel( const Model_t& ); /// set XForms model (only called by Model)
+ css::uno::Reference<css::xforms::XModel> getModel() const { return mxModel;} /// get XForms model
+ void _setModel( const css::uno::Reference<css::xforms::XModel>& ); /// set XForms model (only called by Model)
OUString getModelID() const; /// get ID of XForms model
@@ -215,13 +202,13 @@ public:
// access to a binding's namespace
// (set-method only changes local namespaces (but may add to model))
- XNameContainer_t getBindingNamespaces() const { return mxNamespaces; }
- void setBindingNamespaces( const XNameContainer_t& ); /// get binding nmsp.
+ css::uno::Reference<css::container::XNameContainer> getBindingNamespaces() const { return mxNamespaces; }
+ void setBindingNamespaces( const css::uno::Reference<css::container::XNameContainer>& ); /// get binding nmsp.
// access to the model's namespaces
// (set-method changes model's namespaces (unless a local one is present))
- XNameContainer_t getModelNamespaces() const; /// set model namespaces
- void setModelNamespaces( const XNameContainer_t& ); /// get model nmsp.
+ css::uno::Reference<css::container::XNameContainer> getModelNamespaces() const; /// set model namespaces
+ void setModelNamespaces( const css::uno::Reference<css::container::XNameContainer>& ); /// get model nmsp.
// read-only properties that map MIPs to control data source properties
@@ -245,7 +232,7 @@ public:
std::vector<xforms::EvaluationContext> getMIPEvaluationContexts();
/// get nodeset the bind is bound to
- XNodeList_t getXNodeList();
+ css::uno::Reference<css::xml::dom::XNodeList> getXNodeList();
/// heuristically determine whether this binding is simple binding
/// (here: simple binding == does not depend on other parts of the
@@ -274,48 +261,18 @@ public:
// the ID for XUnoTunnel calls
- static IntSequence_t getUnoTunnelID();
- static Binding* getBinding( const com::sun::star::uno::Reference<com::sun::star::beans::XPropertySet>& );
-
-
- // class-scoped typedef for easy-to-read UNO interfaces
-
-
- // basic types
- typedef com::sun::star::uno::Any Any_t;
- typedef com::sun::star::uno::Sequence<com::sun::star::uno::Type> Sequence_Type_t;
- typedef com::sun::star::uno::Type Type_t;
-
- // reference types
- typedef com::sun::star::uno::Reference<com::sun::star::beans::XPropertyChangeListener> XPropertyChangeListener_t;
- typedef com::sun::star::uno::Reference<com::sun::star::beans::XPropertySetInfo> XPropertySetInfo_t;
- typedef com::sun::star::uno::Reference<com::sun::star::beans::XVetoableChangeListener> XVetoableChangeListener_t;
- typedef com::sun::star::uno::Reference<com::sun::star::xml::xpath::XXPathAPI> XXPathAPI_t;
- typedef com::sun::star::uno::Reference<com::sun::star::xml::dom::events::XEvent> XEvent_t;
- typedef com::sun::star::uno::Reference<com::sun::star::xsd::XDataType> XDataType_t;
-
- // exceptions
- typedef com::sun::star::beans::PropertyVetoException PropertyVetoException_t;
- typedef com::sun::star::beans::UnknownPropertyException UnknownPropertyException_t;
- typedef com::sun::star::lang::IllegalArgumentException IllegalArgumentException_t;
- typedef com::sun::star::lang::NoSupportException NoSupportException_t;
- typedef com::sun::star::lang::WrappedTargetException WrappedTargetException_t;
- typedef com::sun::star::uno::RuntimeException RuntimeException_t;
- typedef com::sun::star::form::binding::IncompatibleTypesException IncompatibleTypesException_t;
- typedef com::sun::star::form::binding::InvalidBindingStateException InvalidBindingStateException_t;
- typedef com::sun::star::lang::NullPointerException NullPointerException_t;
- typedef com::sun::star::lang::IndexOutOfBoundsException IndexOutOfBoundsException_t;
-
+ static css::uno::Sequence<sal_Int8> getUnoTunnelID();
+ static Binding* getBinding( const css::uno::Reference<css::beans::XPropertySet>& );
private:
/// check whether object is live, and throw suitable exception if not
/// (to be used be API methods before acting on the object)
- void checkLive() throw( RuntimeException_t );
+ void checkLive() throw( css::uno::RuntimeException );
/// check whether binding has a model, and throw exception if not
/// (to be used be API methods before acting on the object)
- void checkModel() throw( RuntimeException_t );
+ void checkModel() throw( css::uno::RuntimeException );
/// determine whether object is live
/// live: has model, and model has been initialized
@@ -323,7 +280,7 @@ private:
/// get the model implementation
xforms::Model* getModelImpl() const;
- static xforms::Model* getModelImpl( const Model_t& xModel );
+ static xforms::Model* getModelImpl( const css::uno::Reference<css::xforms::XModel>& xModel );
/// get MIP evaluation contexts
/// (only valid if control has already been bound)
@@ -348,7 +305,7 @@ private:
MIP getLocalMIP() const;
/// get the data type that applies to this binding
- XDataType_t getDataType();
+ css::uno::Reference<css::xsd::XDataType> getDataType();
/// determine whether binding is valid according to the given data type
bool isValid_DataType();
@@ -360,13 +317,13 @@ private:
void clear();
/// distribute MIPs from current node recursively to children
- void distributeMIP( const XNode_t &rxNode );
+ void distributeMIP( const css::uno::Reference<css::xml::dom::XNode> &rxNode );
/// implement get*Namespaces()
- XNameContainer_t _getNamespaces() const;
+ css::uno::Reference<css::container::XNameContainer> _getNamespaces() const;
/// implement set*Namespaces()
- void _setNamespaces( const XNameContainer_t&, bool bBinding );
+ void _setNamespaces( const css::uno::Reference<css::container::XNameContainer>&, bool bBinding );
/// set a useful default binding ID (if none is set)
void _checkBindingID();
@@ -385,21 +342,21 @@ public:
public:
- virtual Sequence_Type_t SAL_CALL getSupportedValueTypes()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Sequence<css::uno::Type> SAL_CALL getSupportedValueTypes()
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual sal_Bool SAL_CALL supportsType( const Type_t& aType )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual sal_Bool SAL_CALL supportsType( const css::uno::Type& aType )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual Any_t SAL_CALL getValue( const Type_t& aType )
- throw( IncompatibleTypesException_t,
- RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Any SAL_CALL getValue( const css::uno::Type& aType )
+ throw( css::form::binding::IncompatibleTypesException,
+ css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual void SAL_CALL setValue( const Any_t& aValue )
- throw( IncompatibleTypesException_t,
- InvalidBindingStateException_t,
- NoSupportException_t,
- RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual void SAL_CALL setValue( const css::uno::Any& aValue )
+ throw( css::form::binding::IncompatibleTypesException,
+ css::form::binding::InvalidBindingStateException,
+ css::lang::NoSupportException,
+ css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
@@ -408,22 +365,22 @@ public:
virtual sal_Int32 SAL_CALL getListEntryCount()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual OUString SAL_CALL getListEntry( sal_Int32 nPosition )
- throw( IndexOutOfBoundsException_t,
- RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::lang::IndexOutOfBoundsException,
+ css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual StringSequence_t SAL_CALL getAllListEntries()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Sequence<OUString> SAL_CALL getAllListEntries()
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual void SAL_CALL addListEntryListener( const XListEntryListener_t& )
- throw( NullPointerException_t,
- RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual void SAL_CALL addListEntryListener( const css::uno::Reference<css::form::binding::XListEntryListener>& )
+ throw( css::lang::NullPointerException,
+ css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual void SAL_CALL removeListEntryListener( const XListEntryListener_t&)
- throw( NullPointerException_t,
- RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual void SAL_CALL removeListEntryListener( const css::uno::Reference<css::form::binding::XListEntryListener>&)
+ throw( css::lang::NullPointerException,
+ css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
@@ -432,22 +389,22 @@ public:
virtual sal_Bool SAL_CALL isValid(
- const Any_t& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ const css::uno::Any& )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual OUString SAL_CALL explainInvalid(
- const Any_t& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ const css::uno::Any& )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL addValidityConstraintListener(
- const XValidityConstraintListener_t& xListener )
- throw( NullPointerException_t,
- RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ const css::uno::Reference<css::form::validation::XValidityConstraintListener>& xListener )
+ throw( css::lang::NullPointerException,
+ css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL removeValidityConstraintListener(
- const XValidityConstraintListener_t& xListener )
- throw( NullPointerException_t,
- RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ const css::uno::Reference<css::form::validation::XValidityConstraintListener>& xListener )
+ throw( css::lang::NullPointerException,
+ css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
@@ -458,12 +415,12 @@ public:
public:
virtual void SAL_CALL addModifyListener(
- const XModifyListener_t& xListener )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ const css::uno::Reference<css::util::XModifyListener>& xListener )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL removeModifyListener(
- const XModifyListener_t& xListener )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ const css::uno::Reference<css::util::XModifyListener>& xListener )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
@@ -476,10 +433,10 @@ public:
public:
virtual OUString SAL_CALL getName()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL setName( const OUString& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
@@ -489,8 +446,8 @@ public:
virtual void SAL_CALL handleEvent(
- const XEvent_t& xEvent )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ const css::uno::Reference<css::xml::dom::events::XEvent>& xEvent )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
@@ -498,16 +455,16 @@ public:
// XUnoTunnel
- virtual sal_Int64 SAL_CALL getSomething( const IntSequence_t& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual sal_Int64 SAL_CALL getSomething( const css::uno::Sequence<sal_Int8>& )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
// XCloneable
- virtual XCloneable_t SAL_CALL createClone()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Reference<css::util::XCloneable> SAL_CALL createClone()
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
};
diff --git a/forms/source/xforms/collection.hxx b/forms/source/xforms/collection.hxx
index 13ad182ccb34..0b50b3ebee4c 100644
--- a/forms/source/xforms/collection.hxx
+++ b/forms/source/xforms/collection.hxx
@@ -42,9 +42,9 @@
typedef cppu::WeakImplHelper3<
- com::sun::star::container::XIndexReplace,
- com::sun::star::container::XSet,
- com::sun::star::container::XContainer>
+ css::container::XIndexReplace,
+ css::container::XSet,
+ css::container::XContainer>
Collection_t;
template<class ELEMENT_TYPE>
@@ -52,8 +52,7 @@ class Collection : public Collection_t
{
public:
typedef ELEMENT_TYPE T;
- typedef com::sun::star::uno::Reference<com::sun::star::container::XContainerListener> XContainerListener_t;
- typedef std::vector<XContainerListener_t> Listeners_t;
+ typedef std::vector<css::uno::Reference<css::container::XContainerListener> > Listeners_t;
protected:
std::vector<T> maItems;
@@ -145,117 +144,106 @@ protected:
public:
- typedef com::sun::star::uno::Type Type_t;
- typedef com::sun::star::uno::Any Any_t;
- typedef com::sun::star::uno::RuntimeException RuntimeException_t;
- typedef com::sun::star::lang::IllegalArgumentException IllegalArgumentException_t;
- typedef com::sun::star::container::NoSuchElementException NoSuchElementException_t;
- typedef com::sun::star::lang::IndexOutOfBoundsException IndexOutOfBoundsException_t;
- typedef com::sun::star::uno::Reference<com::sun::star::container::XEnumeration> XEnumeration_t;
- typedef com::sun::star::lang::WrappedTargetException WrappedTargetException_t;
- typedef com::sun::star::container::ElementExistException ElementExistException_t;
-
-
// XElementAccess
- virtual Type_t SAL_CALL getElementType()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE
+ virtual css::uno::Type SAL_CALL getElementType()
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{
return cppu::UnoType<T>::get();
}
virtual sal_Bool SAL_CALL hasElements()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{
return hasItems();
}
// XIndexAccess : XElementAccess
virtual sal_Int32 SAL_CALL getCount()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{
return countItems();
}
- virtual Any_t SAL_CALL getByIndex( sal_Int32 nIndex )
- throw( IndexOutOfBoundsException_t,
- WrappedTargetException_t,
- RuntimeException_t, std::exception) SAL_OVERRIDE
+ virtual css::uno::Any SAL_CALL getByIndex( sal_Int32 nIndex )
+ throw( css::lang::IndexOutOfBoundsException,
+ css::lang::WrappedTargetException,
+ css::uno::RuntimeException, std::exception) SAL_OVERRIDE
{
if( isValidIndex( nIndex ) )
- return com::sun::star::uno::makeAny( getItem( nIndex ) );
+ return css::uno::makeAny( getItem( nIndex ) );
else
- throw IndexOutOfBoundsException_t();
+ throw css::lang::IndexOutOfBoundsException();
}
// XIndexReplace : XIndexAccess
virtual void SAL_CALL replaceByIndex( sal_Int32 nIndex,
- const Any_t& aElement )
- throw( IllegalArgumentException_t,
- IndexOutOfBoundsException_t,
- WrappedTargetException_t,
- RuntimeException_t, std::exception) SAL_OVERRIDE
+ const css::uno::Any& aElement )
+ throw( css::lang::IllegalArgumentException,
+ css::lang::IndexOutOfBoundsException,
+ css::lang::WrappedTargetException,
+ css::uno::RuntimeException, std::exception) SAL_OVERRIDE
{
T t;
if( isValidIndex( nIndex) )
if( ( aElement >>= t ) && isValid( t ) )
setItem( nIndex, t );
else
- throw IllegalArgumentException_t();
+ throw css::lang::IllegalArgumentException();
else
- throw IndexOutOfBoundsException_t();
+ throw css::lang::IndexOutOfBoundsException();
}
// XEnumerationAccess : XElementAccess
- virtual XEnumeration_t SAL_CALL createEnumeration()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE
+ virtual css::uno::Reference<css::container::XEnumeration> SAL_CALL createEnumeration()
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{
return new Enumeration( this );
}
// XSet : XEnumerationAccess
- virtual sal_Bool SAL_CALL has( const Any_t& aElement )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE
+ virtual sal_Bool SAL_CALL has( const css::uno::Any& aElement )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{
T t;
return ( aElement >>= t ) ? hasItem( t ) : sal_False;
}
- virtual void SAL_CALL insert( const Any_t& aElement )
- throw( IllegalArgumentException_t,
- ElementExistException_t,
- RuntimeException_t, std::exception ) SAL_OVERRIDE
+ virtual void SAL_CALL insert( const css::uno::Any& aElement )
+ throw( css::lang::IllegalArgumentException,
+ css::container::ElementExistException,
+ css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{
T t;
if( ( aElement >>= t ) && isValid( t ) )
if( ! hasItem( t ) )
addItem( t );
else
- throw ElementExistException_t();
+ throw css::container::ElementExistException();
else
- throw IllegalArgumentException_t();
+ throw css::lang::IllegalArgumentException();
}
- virtual void SAL_CALL remove( const Any_t& aElement )
- throw( IllegalArgumentException_t,
- NoSuchElementException_t,
- RuntimeException_t, std::exception ) SAL_OVERRIDE
+ virtual void SAL_CALL remove( const css::uno::Any& aElement )
+ throw( css::lang::IllegalArgumentException,
+ css::container::NoSuchElementException,
+ css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{
T t;
if( aElement >>= t )
if( hasItem( t ) )
removeItem( t );
else
- throw NoSuchElementException_t();
+ throw css::container::NoSuchElementException();
else
- throw IllegalArgumentException_t();
+ throw css::lang::IllegalArgumentException();
}
// XContainer
virtual void SAL_CALL addContainerListener(
- const XContainerListener_t& xListener )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE
+ const css::uno::Reference<css::container::XContainerListener>& xListener )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{
OSL_ENSURE( xListener.is(), "need listener!" );
if( std::find( maListeners.begin(), maListeners.end(), xListener)
@@ -264,8 +252,8 @@ public:
}
virtual void SAL_CALL removeContainerListener(
- const XContainerListener_t& xListener )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE
+ const css::uno::Reference<css::container::XContainerListener>& xListener )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{
OSL_ENSURE( xListener.is(), "need listener!" );
Listeners_t::iterator aIter =
@@ -280,11 +268,11 @@ protected:
void _elementInserted( sal_Int32 nPos )
{
OSL_ENSURE( isValidIndex(nPos), "invalid index" );
- com::sun::star::container::ContainerEvent aEvent(
- static_cast<com::sun::star::container::XIndexReplace*>( this ),
- com::sun::star::uno::makeAny( nPos ),
- com::sun::star::uno::makeAny( getItem( nPos ) ),
- com::sun::star::uno::Any() );
+ css::container::ContainerEvent aEvent(
+ static_cast<css::container::XIndexReplace*>( this ),
+ css::uno::makeAny( nPos ),
+ css::uno::makeAny( getItem( nPos ) ),
+ css::uno::Any() );
for( Listeners_t::iterator aIter = maListeners.begin();
aIter != maListeners.end();
++aIter )
@@ -295,11 +283,11 @@ protected:
void _elementRemoved( const T& aOld )
{
- com::sun::star::container::ContainerEvent aEvent(
- static_cast<com::sun::star::container::XIndexReplace*>( this ),
- com::sun::star::uno::Any(),
- com::sun::star::uno::makeAny( aOld ),
- com::sun::star::uno::Any() );
+ css::container::ContainerEvent aEvent(
+ static_cast<css::container::XIndexReplace*>( this ),
+ css::uno::Any(),
+ css::uno::makeAny( aOld ),
+ css::uno::Any() );
for( Listeners_t::iterator aIter = maListeners.begin();
aIter != maListeners.end();
++aIter )
@@ -311,11 +299,11 @@ protected:
void _elementReplaced( const sal_Int32 nPos, const T& aNew )
{
OSL_ENSURE( isValidIndex(nPos), "invalid index" );
- com::sun::star::container::ContainerEvent aEvent(
- static_cast<com::sun::star::container::XIndexReplace*>( this ),
- com::sun::star::uno::makeAny( nPos ),
- com::sun::star::uno::makeAny( getItem( nPos ) ),
- com::sun::star::uno::makeAny( aNew ) );
+ css::container::ContainerEvent aEvent(
+ static_cast<css::container::XIndexReplace*>( this ),
+ css::uno::makeAny( nPos ),
+ css::uno::makeAny( getItem( nPos ) ),
+ css::uno::makeAny( aNew ) );
for( Listeners_t::iterator aIter = maListeners.begin();
aIter != maListeners.end();
++aIter )
diff --git a/forms/source/xforms/model.cxx b/forms/source/xforms/model.cxx
index c6774ddc0488..0700592a18dc 100644
--- a/forms/source/xforms/model.cxx
+++ b/forms/source/xforms/model.cxx
@@ -171,14 +171,14 @@ EvaluationContext Model::getEvaluationContext()
}
-Model::IntSequence_t Model::getUnoTunnelID()
+css::uno::Sequence<sal_Int8> Model::getUnoTunnelID()
{
static cppu::OImplementationId aImplementationId;
return aImplementationId.getImplementationId();
}
-void Model::setForeignSchema( const XDocument_t& rDocument )
+void Model::setForeignSchema( const css::uno::Reference<css::xml::dom::XDocument>& rDocument )
{
mxForeignSchema = rDocument;
}
@@ -190,7 +190,7 @@ void Model::setSchemaRef( const OUString& rSchemaRef )
}
-void Model::setNamespaces( const XNameContainer_t& rNamespaces )
+void Model::setNamespaces( const css::uno::Reference<css::container::XNameContainer>& rNamespaces )
{
if( rNamespaces.is() )
mxNamespaces = rNamespaces;
@@ -488,7 +488,7 @@ void Model::refresh()
void SAL_CALL Model::submitWithInteraction(
const OUString& sID,
- const XInteractionHandler_t& _rxHandler )
+ const css::uno::Reference<css::task::XInteractionHandler>& _rxHandler )
throw( VetoException,
WrappedTargetException,
RuntimeException, std::exception )
@@ -514,7 +514,7 @@ void Model::submit( const OUString& sID )
submitWithInteraction( sID, NULL );
}
-Model::XDataTypeRepository_t SAL_CALL Model::getDataTypeRepository( )
+css::uno::Reference<css::xforms::XDataTypeRepository> SAL_CALL Model::getDataTypeRepository( )
throw( RuntimeException, std::exception )
{
if ( !mxDataTypes.is() )
@@ -527,13 +527,13 @@ Model::XDataTypeRepository_t SAL_CALL Model::getDataTypeRepository( )
// instance management
-Model::XSet_t Model::getInstances()
+css::uno::Reference<css::container::XSet> Model::getInstances()
throw( RuntimeException, std::exception )
{
return mxInstances;
}
-Model::XDocument_t Model::getInstanceDocument( const OUString& rName )
+css::uno::Reference<css::xml::dom::XDocument> Model::getInstanceDocument( const OUString& rName )
throw( RuntimeException, std::exception )
{
ensureAtLeastOneInstance();
@@ -545,7 +545,7 @@ Model::XDocument_t Model::getInstanceDocument( const OUString& rName )
return aInstance;
}
-Model::XDocument_t SAL_CALL Model::getDefaultInstance()
+css::uno::Reference<css::xml::dom::XDocument> SAL_CALL Model::getDefaultInstance()
throw( RuntimeException, std::exception )
{
ensureAtLeastOneInstance();
@@ -584,7 +584,7 @@ Model::XPropertySet_t Model::getBinding( const OUString& sId )
return mpBindings->hasItem( sId ) ? mpBindings->getItem( sId ) : NULL;
}
-Model::XSet_t Model::getBindings()
+css::uno::Reference<css::container::XSet> Model::getBindings()
throw( RuntimeException, std::exception )
{
DBG_INVARIANT();
@@ -597,34 +597,34 @@ Model::XSet_t Model::getBindings()
// submission management
-Model::XSubmission_t Model::createSubmission()
+css::uno::Reference<css::xforms::XSubmission> Model::createSubmission()
throw( RuntimeException, std::exception )
{
DBG_INVARIANT();
return new Submission();
}
-Model::XSubmission_t Model::cloneSubmission(const XPropertySet_t& xSubmission)
+css::uno::Reference<css::xforms::XSubmission> Model::cloneSubmission(const XPropertySet_t& xSubmission)
throw( RuntimeException, std::exception )
{
DBG_INVARIANT();
- XSubmission_t xNewSubmission = createSubmission();
+ css::uno::Reference<css::xforms::XSubmission> xNewSubmission = createSubmission();
XPropertySet_t xAsPropertySet( xNewSubmission.get() );
copy( xSubmission.get(), xAsPropertySet );
return xNewSubmission;
}
-Model::XSubmission_t Model::getSubmission( const OUString& sId )
+css::uno::Reference<css::xforms::XSubmission> Model::getSubmission( const OUString& sId )
throw( RuntimeException, std::exception )
{
DBG_INVARIANT();
- XSubmission_t xSubmission;
+ css::uno::Reference<css::xforms::XSubmission> xSubmission;
if ( mpSubmissions->hasItem( sId ) )
xSubmission.set(mpSubmissions->getItem( sId ), css::uno::UNO_QUERY);
return xSubmission;
}
-Model::XSet_t Model::getSubmissions()
+css::uno::Reference<css::container::XSet> Model::getSubmissions()
throw( RuntimeException, std::exception )
{
DBG_INVARIANT();
@@ -656,9 +656,9 @@ Model::XSet_t Model::getSubmissions()
void Model::initializePropertySet()
{
REGISTER_PROPERTY_API ( ID, OUString );
- REGISTER_PROPERTY ( ForeignSchema, XDocument_t );
+ REGISTER_PROPERTY ( ForeignSchema, css::uno::Reference<css::xml::dom::XDocument> );
REGISTER_PROPERTY ( SchemaRef, OUString );
- REGISTER_PROPERTY ( Namespaces, XNameContainer_t );
+ REGISTER_PROPERTY ( Namespaces, css::uno::Reference<css::container::XNameContainer> );
REGISTER_BOOL_PROPERTY( ExternalData );
}
@@ -669,7 +669,7 @@ void Model::update()
}
-sal_Int64 Model::getSomething( const IntSequence_t& xId )
+sal_Int64 Model::getSomething( const css::uno::Sequence<sal_Int8>& xId )
throw( RuntimeException, std::exception )
{
return reinterpret_cast<sal_Int64>( ( xId == getUnoTunnelID() ) ? this : NULL );
diff --git a/forms/source/xforms/model.hxx b/forms/source/xforms/model.hxx
index 08de93a3965d..fcb416aeaae1 100644
--- a/forms/source/xforms/model.hxx
+++ b/forms/source/xforms/model.hxx
@@ -68,35 +68,18 @@ namespace xforms
*/
typedef cppu::ImplInheritanceHelper<
PropertySetBase,
- com::sun::star::xforms::XModel2,
- com::sun::star::xforms::XFormsUIHelper1,
- com::sun::star::util::XUpdatable,
- com::sun::star::lang::XUnoTunnel,
+ css::xforms::XModel2,
+ css::xforms::XFormsUIHelper1,
+ css::util::XUpdatable,
+ css::lang::XUnoTunnel,
css::lang::XServiceInfo
> Model_t;
class Model : public Model_t
{
// a number of local typedefs, to make the remaining header readable
- typedef com::sun::star::uno::Reference<com::sun::star::xml::dom::XDocument> XDocument_t;
- typedef com::sun::star::uno::Reference<com::sun::star::xml::dom::XNode> XNode_t;
- typedef com::sun::star::lang::IndexOutOfBoundsException IndexOutOfBoundsException_t;
- typedef com::sun::star::lang::IllegalArgumentException IllegalArgumentException_t;
- typedef com::sun::star::uno::Reference<com::sun::star::beans::XPropertySet> XPropertySet_t;
- typedef com::sun::star::uno::Reference<com::sun::star::xforms::XDataTypeRepository> XDataTypeRepository_t;
- typedef com::sun::star::uno::Reference<com::sun::star::container::XNameContainer> XNameContainer_t;
- typedef com::sun::star::uno::Reference<com::sun::star::xforms::XSubmission> XSubmission_t;
- typedef com::sun::star::uno::Reference<com::sun::star::frame::XModel> Frame_XModel_t;
- typedef com::sun::star::uno::Reference<com::sun::star::xforms::XModel> XModel_t;
- typedef com::sun::star::uno::Reference<com::sun::star::task::XInteractionHandler> XInteractionHandler_t;
-
- typedef com::sun::star::uno::Reference<com::sun::star::container::XSet> XSet_t;
- typedef com::sun::star::beans::PropertyVetoException PropertyVetoException_t;
- typedef com::sun::star::beans::UnknownPropertyException UnknownPropertyException_t;
- typedef com::sun::star::util::VetoException VetoException_t;
- typedef com::sun::star::lang::WrappedTargetException WrappedTargetException_t;
- typedef com::sun::star::uno::RuntimeException RuntimeException_t;
- typedef com::sun::star::uno::Any Any_t;
- typedef com::sun::star::uno::Sequence<sal_Int8> IntSequence_t;
+ typedef css::uno::Reference<css::xml::dom::XNode> XNode_t;
+ typedef css::uno::Reference<css::beans::XPropertySet> XPropertySet_t;
+
typedef std::multimap<XNode_t,std::pair<void*,MIP> > MIPs_t;
@@ -107,18 +90,18 @@ private:
SubmissionCollection* mpSubmissions; /// the submissions
InstanceCollection* mpInstances; /// the instance(s)
- XDataTypeRepository_t mxDataTypes; /// the XSD data-types used
- XDocument_t mxForeignSchema; /// the XSD-schema part we cannot
+ css::uno::Reference<css::xforms::XDataTypeRepository> mxDataTypes; /// the XSD data-types used
+ css::uno::Reference<css::xml::dom::XDocument> mxForeignSchema; /// the XSD-schema part we cannot
/// map onto data types
OUString msSchemaRef; /// xforms:model/@schema attribute
- XNameContainer_t mxNamespaces; /// namespaces for entire model
+ css::uno::Reference<css::container::XNameContainer> mxNamespaces; /// namespaces for entire model
// references to mpBindings/mpSubmissions, for UNO reference counting
- XSet_t mxBindings;
- XSet_t mxSubmissions;
- XSet_t mxInstances;
+ css::uno::Reference<css::container::XSet> mxBindings;
+ css::uno::Reference<css::container::XSet> mxSubmissions;
+ css::uno::Reference<css::container::XSet> mxInstances;
MIPs_t maMIPs; /// map nodes to their MIPs
@@ -137,25 +120,25 @@ public:
virtual ~Model() throw();
// get Model implementation from API object
- static Model* getModel( const com::sun::star::uno::Reference<com::sun::star::xforms::XModel>& );
+ static Model* getModel( const css::uno::Reference<css::xforms::XModel>& );
xforms::EvaluationContext getEvaluationContext();
- static IntSequence_t getUnoTunnelID();
+ static css::uno::Sequence<sal_Int8> getUnoTunnelID();
// get/set that part of the schema, that we can't interpret as data types
- XDocument_t getForeignSchema() const { return mxForeignSchema;}
- void setForeignSchema( const XDocument_t& );
+ css::uno::Reference<css::xml::dom::XDocument> getForeignSchema() const { return mxForeignSchema;}
+ void setForeignSchema( const css::uno::Reference<css::xml::dom::XDocument>& );
// get/set the xforms:model/@schema attribute
OUString getSchemaRef() const { return msSchemaRef;}
void setSchemaRef( const OUString& );
// get/set namespaces for entire model
- XNameContainer_t getNamespaces() const { return mxNamespaces;}
- void setNamespaces( const XNameContainer_t& );
+ css::uno::Reference<css::container::XNameContainer> getNamespaces() const { return mxNamespaces;}
+ void setNamespaces( const css::uno::Reference<css::container::XNameContainer>& );
// get/set the ExternalData property
bool getExternalData() const { return mbExternalData;}
@@ -210,77 +193,77 @@ public:
virtual OUString SAL_CALL getID()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL setID( const OUString& sID )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL initialize()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL rebuild()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL recalculate()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL revalidate()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL refresh()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL submit( const OUString& sID )
- throw( VetoException_t, WrappedTargetException_t, RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::util::VetoException, css::lang::WrappedTargetException, css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual void SAL_CALL submitWithInteraction( const OUString& id, const XInteractionHandler_t& _rxHandler )
- throw( VetoException_t, WrappedTargetException_t, RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual void SAL_CALL submitWithInteraction( const OUString& id, const css::uno::Reference<css::task::XInteractionHandler>& _rxHandler )
+ throw( css::util::VetoException, css::lang::WrappedTargetException, css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual XDataTypeRepository_t SAL_CALL getDataTypeRepository( )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Reference<css::xforms::XDataTypeRepository> SAL_CALL getDataTypeRepository( )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
// XModel: instance management
- virtual XSet_t SAL_CALL getInstances()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Reference<css::container::XSet> SAL_CALL getInstances()
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual XDocument_t SAL_CALL getInstanceDocument( const OUString& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Reference<css::xml::dom::XDocument> SAL_CALL getInstanceDocument( const OUString& )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual XDocument_t SAL_CALL getDefaultInstance()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Reference<css::xml::dom::XDocument> SAL_CALL getDefaultInstance()
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
// XModel: binding management
virtual XPropertySet_t SAL_CALL createBinding()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual XPropertySet_t SAL_CALL cloneBinding( const XPropertySet_t& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual XPropertySet_t SAL_CALL getBinding( const OUString& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual XSet_t SAL_CALL getBindings()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Reference<css::container::XSet> SAL_CALL getBindings()
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
// XModel: submission management
- virtual XSubmission_t SAL_CALL createSubmission()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Reference<css::xforms::XSubmission> SAL_CALL createSubmission()
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual XSubmission_t SAL_CALL cloneSubmission( const XPropertySet_t& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Reference<css::xforms::XSubmission> SAL_CALL cloneSubmission( const XPropertySet_t& )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual XSubmission_t SAL_CALL getSubmission( const OUString& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Reference<css::xforms::XSubmission> SAL_CALL getSubmission( const OUString& )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual XSet_t SAL_CALL getSubmissions()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual css::uno::Reference<css::container::XSet> SAL_CALL getSubmissions()
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
// XPropertySet
@@ -308,7 +291,7 @@ public:
throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{ return PropertySetBase::getPropertySetInfo(); }
- virtual void SAL_CALL setPropertyValue(const OUString& p1, const com::sun::star::uno::Any& p2)
+ virtual void SAL_CALL setPropertyValue(const OUString& p1, const css::uno::Any& p2)
throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE
{ PropertySetBase::setPropertyValue(p1, p2); }
@@ -319,10 +302,10 @@ public:
/// determine a reasonable control service for a given node
/// (based on data type MIP assigned to the node)
- virtual OUString SAL_CALL getDefaultServiceNameForNode( const XNode_t& xNode ) throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
+ virtual OUString SAL_CALL getDefaultServiceNameForNode( const XNode_t& xNode ) throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
/// call getDefaultBindingExpressionForNode with default evaluation context
- virtual OUString SAL_CALL getDefaultBindingExpressionForNode( const XNode_t& xNode ) throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
+ virtual OUString SAL_CALL getDefaultBindingExpressionForNode( const XNode_t& xNode ) throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
/// determine a reasonable default binding expression for a given node
/// and a given evaluation context
@@ -333,88 +316,88 @@ public:
virtual OUString SAL_CALL getNodeDisplayName( const XNode_t&,
sal_Bool bDetail )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual OUString SAL_CALL getNodeName( const XNode_t& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual OUString SAL_CALL getBindingName( const XPropertySet_t&,
sal_Bool bDetail )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual OUString SAL_CALL getSubmissionName( const XPropertySet_t&,
sal_Bool bDetail )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual XPropertySet_t SAL_CALL cloneBindingAsGhost( const XPropertySet_t& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL removeBindingIfUseless( const XPropertySet_t& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual XDocument_t SAL_CALL newInstance( const OUString& sName,
+ virtual css::uno::Reference<css::xml::dom::XDocument> SAL_CALL newInstance( const OUString& sName,
const OUString& sURL,
sal_Bool bURLOnce )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL renameInstance( const OUString& sFrom,
const OUString& sTo,
const OUString& sURL,
sal_Bool bURLOnce )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL removeInstance( const OUString& sName )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual XModel_t SAL_CALL newModel( const Frame_XModel_t& xComponent,
+ virtual css::uno::Reference<css::xforms::XModel> SAL_CALL newModel( const css::uno::Reference<css::frame::XModel>& xComponent,
const OUString& sName )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
- virtual void SAL_CALL renameModel( const Frame_XModel_t& xComponent,
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
+ virtual void SAL_CALL renameModel( const css::uno::Reference<css::frame::XModel>& xComponent,
const OUString& sFrom,
const OUString& sTo )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
- virtual void SAL_CALL removeModel( const Frame_XModel_t& xComponent,
+ virtual void SAL_CALL removeModel( const css::uno::Reference<css::frame::XModel>& xComponent,
const OUString& sName )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual XNode_t SAL_CALL createElement( const XNode_t& xParent,
const OUString& sName )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual XNode_t SAL_CALL createAttribute( const XNode_t& xParent,
const OUString& sName )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual XNode_t SAL_CALL renameNode( const XNode_t& xNode,
const OUString& sName )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual XPropertySet_t SAL_CALL getBindingForNode( const XNode_t&,
sal_Bool bCreate )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL removeBindingForNode( const XNode_t& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual OUString SAL_CALL getResultForExpression(
const XPropertySet_t& xBinding,
sal_Bool bIsBindingExpression,
const OUString& sExpression )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual sal_Bool SAL_CALL isValidXMLName( const OUString& sName )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual sal_Bool SAL_CALL isValidPrefixName( const OUString& sName )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual void SAL_CALL setNodeValue(
const XNode_t& xNode,
const OUString& sValue )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
@@ -423,23 +406,23 @@ public:
public:
virtual void SAL_CALL update()
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
// XUnoTunnel
public:
- virtual sal_Int64 SAL_CALL getSomething( const IntSequence_t& )
- throw( RuntimeException_t, std::exception ) SAL_OVERRIDE;
+ virtual sal_Int64 SAL_CALL getSomething( const css::uno::Sequence<sal_Int8>& )
+ throw( css::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
// XTypeProvider::getImplementationId
public:
- virtual IntSequence_t SAL_CALL getImplementationId()
- throw( RuntimeException_t ) SAL_OVERRIDE;
+ virtual css::uno::Sequence<sal_Int8> SAL_CALL getImplementationId()
+ throw( css::uno::RuntimeException ) SAL_OVERRIDE;
OUString SAL_CALL getImplementationName()
throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
diff --git a/forms/source/xforms/model_helper.hxx b/forms/source/xforms/model_helper.hxx
index c6150b457747..d3254f7127f0 100644
--- a/forms/source/xforms/model_helper.hxx
+++ b/forms/source/xforms/model_helper.hxx
@@ -64,13 +64,13 @@ protected:
virtual void _insert( const T& t ) SAL_OVERRIDE
{
OSL_ENSURE( Binding::getBinding( t ) != NULL, "invalid item?" );
- Binding::getBinding( t )->_setModel( Binding::Model_t( mpModel ) );
+ Binding::getBinding( t )->_setModel( css::uno::Reference<css::xforms::XModel>( mpModel ) );
}
virtual void _remove( const T& t ) SAL_OVERRIDE
{
OSL_ENSURE( Binding::getBinding( t ) != NULL, "invalid item?" );
- Binding::getBinding( t )->_setModel( Binding::Model_t() );
+ Binding::getBinding( t )->_setModel( css::uno::Reference<css::xforms::XModel>() );
}
};
diff --git a/forms/source/xforms/model_ui.cxx b/forms/source/xforms/model_ui.cxx
index 37c122efe314..52843153d103 100644
--- a/forms/source/xforms/model_ui.cxx
+++ b/forms/source/xforms/model_ui.cxx
@@ -406,13 +406,13 @@ void Model::removeBindingIfUseless( const XPropertySet_t& xBinding )
}
}
-Model::XDocument_t Model::newInstance( const OUString& sName,
+css::uno::Reference<css::xml::dom::XDocument> Model::newInstance( const OUString& sName,
const OUString& sURL,
sal_Bool bURLOnce )
throw( RuntimeException, std::exception )
{
// create a default instance with <instanceData> element
- XDocument_t xInstance = getDocumentBuilder()->newDocument();
+ css::uno::Reference<css::xml::dom::XDocument> xInstance = getDocumentBuilder()->newDocument();
DBG_ASSERT( xInstance.is(), "failed to create DOM instance" );
Reference<XNode>( xInstance, UNO_QUERY_THROW )->appendChild(
@@ -517,11 +517,11 @@ static Reference<XNameContainer> lcl_getModels(
return xRet;
}
-Model::XModel_t Model::newModel( const Reference<com::sun::star::frame::XModel>& xCmp,
+css::uno::Reference<css::xforms::XModel> Model::newModel( const Reference<com::sun::star::frame::XModel>& xCmp,
const OUString& sName )
throw( RuntimeException, std::exception )
{
- Model::XModel_t xModel;
+ css::uno::Reference<css::xforms::XModel> xModel;
Reference<XNameContainer> xModels = lcl_getModels( xCmp );
if( xModels.is()
&& ! xModels->hasByName( sName ) )
diff --git a/forms/source/xforms/namedcollection.hxx b/forms/source/xforms/namedcollection.hxx
index d85add0f5897..dd4498d1e7e9 100644
--- a/forms/source/xforms/namedcollection.hxx
+++ b/forms/source/xforms/namedcollection.hxx
@@ -91,41 +91,41 @@ protected:
public:
// XElementAccess
- virtual typename Collection<T>::Type_t SAL_CALL getElementType()
- throw( typename Collection<T>::RuntimeException_t ) SAL_OVERRIDE
+ virtual css::uno::Type SAL_CALL getElementType()
+ throw( css::uno::RuntimeException ) SAL_OVERRIDE
{
return Collection<T>::getElementType();
}
virtual sal_Bool SAL_CALL hasElements()
- throw( typename Collection<T>::RuntimeException_t ) SAL_OVERRIDE
+ throw( css::uno::RuntimeException ) SAL_OVERRIDE
{
return Collection<T>::hasElements();
}
// XNameAccess : XElementAccess
- virtual typename Collection<T>::Any_t SAL_CALL getByName(
+ virtual css::uno::Any SAL_CALL getByName(
const OUString& aName )
- throw( typename Collection<T>::NoSuchElementException_t,
- typename Collection<T>::WrappedTargetException_t,
- typename Collection<T>::RuntimeException_t ) SAL_OVERRIDE
+ throw( css::container::NoSuchElementException,
+ css::lang::WrappedTargetException,
+ css::uno::RuntimeException ) SAL_OVERRIDE
{
if( hasItem( aName ) )
return com::sun::star::uno::makeAny( getItem( aName ) );
else
- throw typename Collection<T>::NoSuchElementException_t();
+ throw css::container::NoSuchElementException();
}
virtual Names_t SAL_CALL getElementNames()
- throw( typename Collection<T>::RuntimeException_t ) SAL_OVERRIDE
+ throw( css::uno::RuntimeException ) SAL_OVERRIDE
{
return getNames();
}
virtual sal_Bool SAL_CALL hasByName(
const OUString& aName )
- throw( typename Collection<T>::RuntimeException_t ) SAL_OVERRIDE
+ throw( css::uno::RuntimeException ) SAL_OVERRIDE
{
return hasItem( aName ) ? sal_True : sal_False;
}
diff --git a/forms/source/xforms/xformsevent.cxx b/forms/source/xforms/xformsevent.cxx
index 04a06004e47c..7b12a235e23d 100644
--- a/forms/source/xforms/xformsevent.cxx
+++ b/forms/source/xforms/xformsevent.cxx
@@ -39,17 +39,17 @@ OUString SAL_CALL XFormsEventConcrete::getType() throw (RuntimeException, std::e
return m_eventType;
}
-XFormsEventConcrete::XEventTarget_t SAL_CALL XFormsEventConcrete::getTarget() throw (RuntimeException, std::exception)
+css::uno::Reference< css::xml::dom::events::XEventTarget > SAL_CALL XFormsEventConcrete::getTarget() throw (RuntimeException, std::exception)
{
return m_target;
}
-XFormsEventConcrete::XEventTarget_t SAL_CALL XFormsEventConcrete::getCurrentTarget() throw (RuntimeException, std::exception)
+css::uno::Reference< css::xml::dom::events::XEventTarget > SAL_CALL XFormsEventConcrete::getCurrentTarget() throw (RuntimeException, std::exception)
{
return m_currentTarget;
}
-XFormsEventConcrete::PhaseType_t SAL_CALL XFormsEventConcrete::getEventPhase() throw (RuntimeException, std::exception)
+css::xml::dom::events::PhaseType SAL_CALL XFormsEventConcrete::getEventPhase() throw (RuntimeException, std::exception)
{
return m_phase;
}
@@ -64,7 +64,7 @@ sal_Bool SAL_CALL XFormsEventConcrete::getCancelable() throw (RuntimeException,
return m_cancelable;
}
-XFormsEventConcrete::Time_t SAL_CALL XFormsEventConcrete::getTimeStamp() throw (RuntimeException, std::exception)
+css::util::Time SAL_CALL XFormsEventConcrete::getTimeStamp() throw (RuntimeException, std::exception)
{
return m_time;
}
diff --git a/forms/source/xforms/xformsevent.hxx b/forms/source/xforms/xformsevent.hxx
index e8ce811a94de..5628208ad4ad 100644
--- a/forms/source/xforms/xformsevent.hxx
+++ b/forms/source/xforms/xformsevent.hxx
@@ -34,11 +34,6 @@ class XFormsEventConcrete : public cppu::WeakImplHelper1< XFormsEvent > {
public:
- typedef com::sun::star::uno::RuntimeException RuntimeException_t;
- typedef com::sun::star::uno::Reference< com::sun::star::xml::dom::events::XEventTarget > XEventTarget_t;
- typedef com::sun::star::xml::dom::events::PhaseType PhaseType_t;
- typedef com::sun::star::util::Time Time_t;
-
XFormsEventConcrete()
: m_canceled(false)
, m_phase(com::sun::star::xml::dom::events::PhaseType_CAPTURING_PHASE)
@@ -48,27 +43,27 @@ class XFormsEventConcrete : public cppu::WeakImplHelper1< XFormsEvent > {
}
virtual ~XFormsEventConcrete() {}
- virtual OUString SAL_CALL getType() throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
- virtual XEventTarget_t SAL_CALL getTarget() throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
- virtual XEventTarget_t SAL_CALL getCurrentTarget() throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
- virtual PhaseType_t SAL_CALL getEventPhase() throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
- virtual sal_Bool SAL_CALL getBubbles() throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
- virtual sal_Bool SAL_CALL getCancelable() throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
- virtual Time_t SAL_CALL getTimeStamp() throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
- virtual void SAL_CALL stopPropagation() throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
- virtual void SAL_CALL preventDefault() throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
+ virtual OUString SAL_CALL getType() throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+ virtual css::uno::Reference< css::xml::dom::events::XEventTarget > SAL_CALL getTarget() throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+ virtual css::uno::Reference< css::xml::dom::events::XEventTarget > SAL_CALL getCurrentTarget() throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+ virtual css::xml::dom::events::PhaseType SAL_CALL getEventPhase() throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+ virtual sal_Bool SAL_CALL getBubbles() throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+ virtual sal_Bool SAL_CALL getCancelable() throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+ virtual css::util::Time SAL_CALL getTimeStamp() throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+ virtual void SAL_CALL stopPropagation() throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+ virtual void SAL_CALL preventDefault() throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
virtual void SAL_CALL initXFormsEvent(
const OUString& typeArg,
sal_Bool canBubbleArg,
sal_Bool cancelableArg )
- throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
virtual void SAL_CALL initEvent(
const OUString& eventTypeArg,
sal_Bool canBubbleArg,
sal_Bool cancelableArg)
- throw (RuntimeException_t, std::exception) SAL_OVERRIDE;
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
private:
@@ -77,12 +72,12 @@ class XFormsEventConcrete : public cppu::WeakImplHelper1< XFormsEvent > {
protected:
OUString m_eventType;
- XEventTarget_t m_target;
- XEventTarget_t m_currentTarget;
- PhaseType_t m_phase;
+ css::uno::Reference< css::xml::dom::events::XEventTarget > m_target;
+ css::uno::Reference< css::xml::dom::events::XEventTarget > m_currentTarget;
+ css::xml::dom::events::PhaseType m_phase;
bool m_bubbles;
bool m_cancelable;
- Time_t m_time;
+ css::util::Time m_time;
};
} } } }