|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object fr.cnes.sirius.patrius.assembly.Assembly
public class Assembly
This class describes an assembly by all its sub parts.
This assembly shall be created and modified using the associated builder. Then user can access to each part by its name and get its properties. This assembly does not include the physical models : models shall be created in separated classes using this one.
AssemblyBuilder
,
MainPart
,
Part
,
Serialized FormField Summary | |
---|---|
static String |
FRAME
String Frame |
Constructor Summary | |
---|---|
protected |
Assembly()
Assembly simple constructor. |
Method Summary | |
---|---|
void |
addMainPart(MainPart part)
Adds the main part to the assembly. |
void |
addPart(IPart part)
Adds a part to the assembly. |
Set<String> |
getAllPartsNames()
Gets the list of the name of the parts in the assembly (the main part is excluded). |
MainPart |
getMainPart()
|
IPart |
getPart(String name)
Returns the part whose name is specified. |
Map<String,IPart> |
getParts()
Returns all the parts of the assembly. |
void |
initMainPartFrame(SpacecraftState state)
Initialize the main part's frame using a SpacecraftState as an input argument. |
void |
initMainPartFrame(UpdatableFrame frame)
Initialize the main part's frame using a UpdatableFrame as an input argument. |
void |
removePart(String partName)
Removes a part from the assembly. |
void |
updateMainPartFrame(SpacecraftState state)
Updates the main part frame's transformation to its parent frame using a Transform as an input argument. |
void |
updateMainPartFrame(Transform transform)
Updates the main part frame's transformation to its parent frame using a Transform
as an input argument. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String FRAME
Constructor Detail |
---|
protected Assembly()
Method Detail |
---|
public final void addPart(IPart part)
part
- the part to add to the assembly
IllegalArgumentException
- if a part with this name already exists or if the main part has not been created yet.public final void addMainPart(MainPart part)
part
- the main part to add
IllegalArgumentException
- if the main part is already createdpublic final void removePart(String partName)
partName
- the name of the part to remove
IllegalArgumentException
- if no part has this namepublic final IPart getPart(String name)
name
- the name of the part
IllegalArgumentException
- if no part has this namepublic final MainPart getMainPart()
public final Map<String,IPart> getParts()
public final Set<String> getAllPartsNames()
public final void initMainPartFrame(UpdatableFrame frame)
UpdatableFrame
as an input argument.
This allows the user to link the entire assembly frame tree to the Orekit frames tree
(if argument frame
) is in the OREKIT Frames tree (see FramesFactory
).
This method asks for an UpdatableFrame that will later allow to redefine its transformation.
frame
- the new main part's framepublic final void initMainPartFrame(SpacecraftState state) throws OrekitException
SpacecraftState
as an input argument.
The main part's parent frame is then the SpacecraftState's definition frame.
This allows the user to link the entire assembly frame tree to the Orekit frames tree.
state
- the SpacecraftState defining the position and orientation of the main part
in its parent frame
OrekitException
- if no attitude is definedpublic final void updateMainPartFrame(Transform transform) throws OrekitException
Transform
as an input argument.
It is assumed that user has already defined a UpdatableFrame
for the main part (using
initMainPartFrame(UpdatableFrame)
or initMainPartFrame(SpacecraftState)
).
If that is not the case, an IllegalArgumentException
is thrown.
transform
- the Transform
OrekitException
- if a problem occurs during frames transformations
IllegalArgumentException
- if the main frame has no parent yetpublic final void updateMainPartFrame(SpacecraftState state) throws OrekitException
Transform
as an input argument.
It is assumed that user has already defined a UpdatableFrame
for the main part (using
initMainPartFrame(UpdatableFrame)
or initMainPartFrame(SpacecraftState)
).
If that is not the case, an IllegalArgumentException
is thrown.
state
- the SpacecraftState
OrekitException
- if a problem occurs during frames transformations
IllegalArgumentException
- if the main frame has no parent yet
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |