public abstract class ParticleConstraintBase extends ConstrainerBase implements ScalableUnits
ModelComponent.NavpanelVisibility
Modifier and Type | Field and Description |
---|---|
static PropertyList |
myProps |
enforceUniqueCompositeNames, enforceUniqueNames, myNumber, NULL_OBJ, useCompactPathNames
TRANSPARENT, TWO_DIMENSIONAL
Constructor and Description |
---|
ParticleConstraintBase() |
Modifier and Type | Method and Description |
---|---|
int |
addBilateralConstraints(SparseBlockMatrix GT,
VectorNd dg,
int numb) |
void |
addParticle(Particle p) |
void |
addParticles(java.util.Collection<? extends Particle> parts) |
int |
addUnilateralConstraints(SparseBlockMatrix NT,
VectorNd dg,
int numu) |
PropertyList |
getAllPropertyInfo()
Returns a list giving static information about all properties exported by
this object.
|
int |
getBilateralForces(VectorNd lam,
int idx) |
int |
getBilateralInfo(MechSystem.ConstraintInfo[] ginfo,
int idx) |
void |
getBilateralSizes(VectorNi sizes) |
double |
getCompliance() |
void |
getConstrainedComponents(java.util.List<DynamicComponent> list) |
double |
getDamping() |
Particle |
getParticle(int idx) |
double |
getPenetrationTol() |
void |
getSoftReferences(java.util.List<ModelComponent> refs)
Appends all soft references for this component to a list.
|
void |
getState(DataBuffer data)
Saves state information for this component by adding data to the
supplied DataBuffer.
|
int |
getUnilateralForces(VectorNd the,
int idx) |
int |
getUnilateralInfo(MechSystem.ConstraintInfo[] ninfo,
int idx) |
void |
getUnilateralSizes(VectorNi sizes) |
boolean |
isEngaged(int idx) |
boolean |
isUnilateral() |
int |
numParticles() |
boolean |
removeParticle(Particle p) |
int |
setBilateralForces(VectorNd lam,
double s,
int idx) |
void |
setCompliance(double c) |
void |
setDamping(double d) |
void |
setPenetrationTol(double tol) |
void |
setState(DataBuffer data)
Restores the state for this component by reading from the supplied
data buffer, starting at the current buffer offsets.
|
void |
setUnilateral(boolean unilateral) |
int |
setUnilateralForces(VectorNd the,
double s,
int idx) |
void |
updateReferences(boolean undo,
java.util.Deque<java.lang.Object> undoInfo)
May be called by the system if any of the soft references for
this component are removed from the the component hierarchy.
|
void |
zeroForces() |
addFrictionConstraints, advanceState, hasState, maxFrictionConstraintSets, updateConstraints
copy, createRenderProps, getRenderHints, getRenderProps, getSelection, isSelectable, isVisible, numSelectionQueriesNeeded, prerender, render, setRenderProps, setVisible, updateBounds, updateRenderProps
checkFlag, checkName, checkNameUniqueness, clearFlag, clone, connectToHierarchy, createTempFlag, disconnectFromHierarchy, getChildren, getGrandParent, getHardReferences, getName, getNameRange, getNavpanelVisibility, getNavpanelVisibility, getNumber, getParent, getProperty, hasChildren, isFixed, isMarked, isScanning, isSelected, isWritable, makeValidName, makeValidName, notifyParentOfChange, postscan, printReferences, recursivelyContained, recursivelyContains, removeTempFlag, scan, setFixed, setFlag, setMarked, setName, setNavpanelVisibility, setNavpanelVisibility, setNumber, setParent, setScanning, setSelected, write
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
scaleDistance, scaleMass
getStateVersion
connectToHierarchy, disconnectFromHierarchy, getHardReferences, getName, getNavpanelVisibility, getNumber, getParent, isFixed, isMarked, isSelected, notifyParentOfChange, scan, setFixed, setMarked, setName, setNumber, setParent, setSelected
getProperty
getChildren, hasChildren
postscan
isWritable, write
public static PropertyList myProps
public PropertyList getAllPropertyInfo()
HasProperties
getAllPropertyInfo
in interface HasProperties
getAllPropertyInfo
in class ModelComponentBase
public double getDamping()
public void setDamping(double d)
public double getCompliance()
public void setCompliance(double c)
public double getPenetrationTol()
public void setPenetrationTol(double tol)
public boolean isUnilateral()
public void setUnilateral(boolean unilateral)
public void addParticle(Particle p)
public void addParticles(java.util.Collection<? extends Particle> parts)
public Particle getParticle(int idx)
public int numParticles()
public boolean removeParticle(Particle p)
public void getBilateralSizes(VectorNi sizes)
getBilateralSizes
in interface Constrainer
getBilateralSizes
in class ConstrainerBase
public int addBilateralConstraints(SparseBlockMatrix GT, VectorNd dg, int numb)
addBilateralConstraints
in interface Constrainer
addBilateralConstraints
in class ConstrainerBase
public int getBilateralInfo(MechSystem.ConstraintInfo[] ginfo, int idx)
getBilateralInfo
in interface Constrainer
getBilateralInfo
in class ConstrainerBase
public int setBilateralForces(VectorNd lam, double s, int idx)
setBilateralForces
in interface Constrainer
setBilateralForces
in class ConstrainerBase
public int getBilateralForces(VectorNd lam, int idx)
getBilateralForces
in interface Constrainer
getBilateralForces
in class ConstrainerBase
public void getUnilateralSizes(VectorNi sizes)
getUnilateralSizes
in interface Constrainer
getUnilateralSizes
in class ConstrainerBase
public int addUnilateralConstraints(SparseBlockMatrix NT, VectorNd dg, int numu)
addUnilateralConstraints
in interface Constrainer
addUnilateralConstraints
in class ConstrainerBase
public int getUnilateralInfo(MechSystem.ConstraintInfo[] ninfo, int idx)
getUnilateralInfo
in interface Constrainer
getUnilateralInfo
in class ConstrainerBase
public int setUnilateralForces(VectorNd the, double s, int idx)
setUnilateralForces
in interface Constrainer
setUnilateralForces
in class ConstrainerBase
public int getUnilateralForces(VectorNd the, int idx)
getUnilateralForces
in interface Constrainer
getUnilateralForces
in class ConstrainerBase
public void zeroForces()
zeroForces
in interface Constrainer
zeroForces
in class ConstrainerBase
public boolean isEngaged(int idx)
public void getConstrainedComponents(java.util.List<DynamicComponent> list)
getConstrainedComponents
in interface Constrainer
getConstrainedComponents
in class ConstrainerBase
public void getSoftReferences(java.util.List<ModelComponent> refs)
ModelComponentBase
updateReferences()
method will
be called to update its internal reference information.getSoftReferences
in interface ModelComponent
getSoftReferences
in class ModelComponentBase
refs
- list to which soft references are appendedpublic void updateReferences(boolean undo, java.util.Deque<java.lang.Object> undoInfo)
ModelComponentBase
undo
equal to false
,
this component should then examine its soft references and
use ComponentUtils.areConnected()
to determine which of them have been disconnected from the hierarchy.
Disconnected references should be removed, and sufficient information
should be appended to undoInfo
to allow this update
to be undone if this method is called later with undo
equal to true
. When undoing an update, the undo
information should be removed from the front of undoInfo
.updateReferences
in interface ModelComponent
updateReferences
in class ModelComponentBase
undo
- if true
, indicates that the most
recent reference update should be undone, using the supplied
undo information.undoInfo
- if undo
is false
, should be used
to store information allowing the reference update to be undone.
Otherwise, if undo
is true
, then this
supplied information to undo the most recent update.public void getState(DataBuffer data)
HasNumericState
getState
in interface HasNumericState
getState
in class ConstrainerBase
data
- buffer for storing the state values.public void setState(DataBuffer data)
HasNumericState
setState
in interface HasNumericState
setState
in class ConstrainerBase
data
- buffer containing the state information