Language
Asturianu (ast)
Català (ca)
Čeština (cs)
Dansk (da)
Deutsch (de)
English [US] (en-US)
Español (es)
Esperanto (eo)
Eesti keel (et)
Euskara (eu)
Français (fr)
Gàidhlig (gd)
Galego (gl)
Italiano (it)
Lietuvių (lt)
Magyar (hu)
Nederlands (nl)
Norsk (no)
Polski (pl)
Português [do Brasil] (pt-BR)
Português [Europeu] (pt)
Română (ro)
Slovenčina (sk)
Slovenščina (sl)
Suomi (fi)
Svenska (sv)
Yкраїнська (uk)
Tiếng Việt (vi)
Türkçe (tr)
ኦሮሚኛ (om)
Հայերեն (hy)
Ελληνικά (el)
български език (bg)
Русский (ru)
Cрпски [ћирилицом] (sr)
עברית (he)
हिन्दी (hi)
ភាសាខ្មែរ (km)
தமிழ் (ta)
ภาษาไทย (th)
简体中文 (zh-CN)
正體中文 (zh-TW)
日本語 (ja)
한국어 (ko)
The Free and Open Productivity Suite
:: com :: sun :: star :: awt :: grid ::
interface XGridColumnModel
Base Interfaces
XGridColumnModel
┣ ::com::sun::star::lang ::XComponent
┣ ::com::sun::star::container ::XContainer
┗ ::com::sun::star::util ::XCloneable
::com::sun::star::lang ::XComponent
Description
implements life time control for the component
::com::sun::star::container ::XContainer
Description
allows to register listeners to be notified when columns are inserted or removed
::com::sun::star::util ::XCloneable
Description
allows cloning the complete column model
Description
An instance of this interface is used by the UnoControlGrid to
retrieve the column structure that is displayed in the actual control.
If you do not need your own model implementation, you can also use the DefaultGridColumnModel .
Since
OOo 3.3
Methods' Details
getColumnCount
Description
Returns the number of columns.
Returns
the number of columns.
createColumn
Description
creates a new column for use with the column model.
The newly created column is not yet inserted into the column container, you need to call addColumn
after you initialized the column object.
addColumn
Description
Adds a column to the model.
You should use the createColumn member to create a new column. This gives
implementations of the XGridColumnModel
interface the possibility to provide own column
implementations which extend the basic GridColumn type.
As soon as the column has been inserted into the model, the model takes ownership of it. This means when the
column is removed, or when the column model is disposed, the grid column is disposed as well.
Parameter column
the column to add to the model.
Returns
the index of new created column.
Throws
::com::sun::star::lang::IllegalArgumentException
if the given column is not a valid element for the column container, or if it is NULL .
removeColumn
Description
removes a column from the model
The column object will be disposed upon removal.
Parameter ColumnIndex
denotes the index of the column to remove
Throws
::com::sun::star::lang::IndexOutOfBoundsException
if ColumnIndex
does not denote a valid column index.
getColumns
Description
Returns all columns of the model.
Returns
all columns associated with the model in a sequence of XGridColumn .
getColumn
Description
Returns a specific column.
Parameter index
the position of the requested column.
Returns
the requested column.
setDefaultColumns
void
setDefaultColumns (
[in] long
elements );
Description
Fills the model with the given number of default columns
Existing columns will be removed before adding new columns. Listeners at the column model will
be notified one ::com::sun::star::container ::XContainerListener ::elementRemoved event
for each removed column, and one ::com::sun::star::container ::XContainerListener ::elementInserted
event for each insertion.
Parameter elements
the number of default columns that should be set.
Top of Page Copyright © 2013, The Apache Software Foundation, Licensed under the Apache License, Version 2.0. Apache, the Apache feather logo, Apache OpenOffice and OpenOffice.org are trademarks of The Apache Software Foundation. Other names may be trademarks of their respective owners.