1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance 9 * with the License. You may obtain a copy of the License at 10 * 11 * http://www.apache.org/licenses/LICENSE-2.0 12 * 13 * Unless required by applicable law or agreed to in writing, 14 * software distributed under the License is distributed on an 15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16 * KIND, either express or implied. See the License for the 17 * specific language governing permissions and limitations 18 * under the License. 19 * 20 *************************************************************/ 21 22 23#ifndef __com_sun_star_awt_tree_XMutableTreeDataModel_idl__ 24#define __com_sun_star_awt_tree_XMutableTreeDataModel_idl__ 25 26#ifndef __com_sun_star_awt_tree_XTreeDataModel_idl__ 27#include <com/sun/star/awt/tree/XTreeDataModel.idl> 28#endif 29 30#ifndef __com_sun_star_awt_tree_XMutableTreeNode_idl__ 31#include <com/sun/star/awt/tree/XMutableTreeNode.idl> 32#endif 33 34//============================================================================= 35 36module com { module sun { module star { module awt { module tree { 37 38//============================================================================= 39 40/** This is the editable version of the <type>XTreeDataModel</type>. 41 42 <p>Note that only <type>XTreeNode</type> created from the same instance with <member>createNode</member> 43 are valids nodes for this instance.</p> 44 */ 45published interface XMutableTreeDataModel : XTreeDataModel 46{ 47 /** creates a new tree node with the given value and given settings. 48 49 @param DisplayValue 50 should be convertable to a string and is used by the <type>XTreeControl</type> 51 as a textual represenation of the created node. 52 53 @param ChildrenOnDemand 54 if <TRUE/> is used as a parameter, the created node will be treated as a non-leaf 55 node by the <type>XTreeControl</type>, even when it has no child nodes. 56 57 @returns 58 a new <type>XMutableTreeNode</type> that can be used for this model. 59 60 @see XTreeNode::getDisplayValue() 61 @see XTreeNode::hasChildrenOnDemand() 62 */ 63 XMutableTreeNode createNode( [in] any DisplayValue, [in] boolean ChildrenOnDemand ); 64 65 /** changes the root node of this model to <var>RootNode</var>. 66 67 @param RootNode 68 the <type>XMutableTreeNode</type> that becomes the new root node of this model. 69 70 @throws ::com::sun::star::lang::IllegalArgumentException 71 if <var>RootNode</var> is not a valid node of this <type>XTreeDataModel</type>. 72 */ 73 void setRoot( [in] XMutableTreeNode RootNode ) 74 raises( ::com::sun::star::lang::IllegalArgumentException ); 75}; 76 77//============================================================================= 78 79}; }; }; }; }; 80 81#endif 82