Package com.comsol.model
Interface Selection
-
- All Superinterfaces:
AbstractSelection
,ModelEntity
,PrimitiveModelEntity
- All Known Subinterfaces:
HideGeom
,HideMesh
,LocalSelection
,MeshSelection
,SavePointHideGeom
,SavePointSelection
,SelectionFeature
,XDLocalSelection
public interface Selection extends AbstractSelection
Selection.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description Selection
add(int... entities)
Adds the given entities to the selection.Selection
all()
Select all geometric entities (not including void regions) in the current dimension.Selection
allgeom()
Deprecated.UseallGeom()
instead.Selection
allGeom()
Sets the selection to the whole geometry.Selection
allVoids()
Select all void regions.Selection
clear()
Removes all entities from the selection.int[]
dom(int arg0)
Deprecated.Useentities(int)
instead.int[]
entities()
If the selection is on a geometry, return the geometric entities in the selection's maximum dimension.int[]
entities(int dim)
If the selection is on a geometry, return the geometric entities on the given dimension.Selection
geom(int dim)
Sets the selection to be the geometric entities of leveldim
.Selection
geom(java.lang.String geom)
Sets the selection to a geometrygeom
.Selection
geom(java.lang.String geom, int dim)
Sets the selection to be the geometric entities of leveldim
on geometrygeom
.Selection
geom(java.lang.String geom, int highdim, int lowdim, java.lang.String[] typelist)
Sets the selection to be the geometric entities of levellowdim
on geometrygeom
.Selection
global()
Makes the selection global.Selection
inherit(boolean flag)
Sets the inherit flag.int
inputDimension()
Get the dimension of the geometric entities used as input.int[]
inputEntities()
Get the geometric entities used as input to the selection.int[]
interiordom(int arg0)
Deprecated.UseinteriorEntities(int)
instead.int[]
interiorEntities(int dim)
If the selection is on a geometry, return the interior entities of the given dimension.boolean
isgeom()
Deprecated.UseisGeom()
instead.boolean
isGeom()
Returnstrue
if the selection is a whole geometry.boolean
isglobal()
Deprecated.UseisGlobal()
instead.boolean
isGlobal()
Returnstrue
if the selection is global.boolean
isinheriting()
Deprecated.UseisInheriting()
instead.boolean
isInheriting()
Returnstrue
if the selection is inherited to lower dimension levels.Selection
remove(int... entities)
Removes the given entities from the selection.Selection
set(int... entities)
Sets the selection to use the given geometric entities.-
Methods inherited from interface com.comsol.model.AbstractSelection
dim, dimension, geom
-
Methods inherited from interface com.comsol.model.ModelEntity
active, author, author, comments, comments, dateCreated, dateModified, docMarker, docMarker, help, help, icon, isactive, isActive, label, label, lastModifiedBy, model, model, name, name, resetAuthor, scope, tag, tag, timeCreated, timeModified, version, version
-
Methods inherited from interface com.comsol.model.PrimitiveModelEntity
getContainer, getDisplayString, resolveModelPath
-
-
-
-
Method Detail
-
add
Selection add(int... entities)
Adds the given entities to the selection.- Parameters:
entities
- Geometric entities to add to the selection.- Returns:
- Selection.
-
all
Selection all()
Select all geometric entities (not including void regions) in the current dimension.- Returns:
- Selection.
-
allGeom
Selection allGeom()
Sets the selection to the whole geometry. Can be used instead ofgeom(String)
when the geometry is unambiguous.- Returns:
- Selection.
-
allVoids
Selection allVoids()
Select all void regions.- Returns:
- Selection.
-
clear
Selection clear()
Removes all entities from the selection.- Returns:
- Selection.
-
dom
@Deprecated int[] dom(int arg0)
Deprecated.Useentities(int)
instead.
-
entities
int[] entities()
If the selection is on a geometry, return the geometric entities in the selection's maximum dimension.- Returns:
- Vector of geometric entities.
-
entities
int[] entities(int dim)
If the selection is on a geometry, return the geometric entities on the given dimension.- Parameters:
dim
- Dimension to analyze.- Returns:
- Vector of geometric entities.
-
geom
Selection geom(java.lang.String geom)
Sets the selection to a geometrygeom
.- Parameters:
geom
- Geometry tag.- Returns:
- Selection.
-
geom
Selection geom(int dim)
Sets the selection to be the geometric entities of leveldim
. Can be used instead ofgeom(String, int)
when the geometry is unambiguous.- Parameters:
dim
- Geometric entity level.- Returns:
- Selection.
-
geom
Selection geom(java.lang.String geom, int dim)
Sets the selection to be the geometric entities of leveldim
on geometrygeom
.- Parameters:
geom
- Geometry tag.dim
- Geometry entity level.- Returns:
- Selection.
-
geom
Selection geom(java.lang.String geom, int highdim, int lowdim, java.lang.String[] typelist)
Sets the selection to be the geometric entities of levellowdim
on geometrygeom
. The input is given on levelhighdim
and the output is calculated using the given types, which can beexterior
,interior
,meshinterior
.- Parameters:
geom
- Geometry tag.highdim
- Geometric entity level for selection input.lowdim
- Geometric entity level for selection output.typelist
- Types included in output.- Returns:
- Selection.
-
global
Selection global()
Makes the selection global.- Returns:
- Selection.
-
inherit
Selection inherit(boolean flag)
Sets the inherit flag.- Parameters:
flag
- Inherit flag.- Returns:
- Selection.
-
inputDimension
int inputDimension()
Get the dimension of the geometric entities used as input. If the selection is of the typeinterior
,exterior
, ormeshinterior
, this method returns the higher dimension with the input domains. If the selection is not a selection of entities in a specified dimension, this method returns -1.- Returns:
- Selection input dimension.
-
inputEntities
int[] inputEntities()
Get the geometric entities used as input to the selection. If the selection is of the typeinterior
,exterior
, ormeshinterior
. this method returns the unfiltered list of domains at the higher dimension which are used as the input. If the selection is not a selection of domains at a certain level or the selection is not of the types Explicit or FromGeom (derived from a geometry feature), this method returns null.- Returns:
- Selection input entities.
-
interiorEntities
int[] interiorEntities(int dim)
If the selection is on a geometry, return the interior entities of the given dimension.- Parameters:
dim
- Dimension to analyze.- Returns:
- List of interior entities.
-
interiordom
@Deprecated int[] interiordom(int arg0)
Deprecated.UseinteriorEntities(int)
instead.
-
isGeom
boolean isGeom()
Returnstrue
if the selection is a whole geometry.- Returns:
true
if a whole geometry.
-
isGlobal
boolean isGlobal()
Returnstrue
if the selection is global.- Returns:
true
if a global selection.
-
isInheriting
boolean isInheriting()
Returnstrue
if the selection is inherited to lower dimension levels.- Returns:
true
if the selection is inherited.
-
isgeom
@Deprecated boolean isgeom()
Deprecated.UseisGeom()
instead.
-
isglobal
@Deprecated boolean isglobal()
Deprecated.UseisGlobal()
instead.
-
isinheriting
@Deprecated boolean isinheriting()
Deprecated.UseisInheriting()
instead.
-
remove
Selection remove(int... entities)
Removes the given entities from the selection.- Parameters:
entities
- Geometric entities to remove from the selection.- Returns:
- Selection.
-
set
Selection set(int... entities)
Sets the selection to use the given geometric entities.- Parameters:
entities
- Geometric entities.- Returns:
- Selection.
-
-