synergynetframework.appsystem.contentsystem.jme
Class JMEContentSystem

java.lang.Object
  extended by synergynetframework.appsystem.contentsystem.ContentSystem
      extended by synergynetframework.appsystem.contentsystem.jme.JMEContentSystem

public class JMEContentSystem
extends ContentSystem

The Class JMEContentSystem.


Constructor Summary
JMEContentSystem()
          Instantiates a new JME content system.
JMEContentSystem(com.jme.scene.Node orthoNode)
          Instantiates a new JME content system.
 
Method Summary
 void addContentItem(ContentItem contentItem)
          Adds the content item.
 ContentItem createContentItem(java.lang.Class<? extends ContentItem> contentItemType)
          Create a content item where the name will be auto-generated.
 ContentItem createContentItem(java.lang.Class<? extends ContentItem> contentItemType, java.lang.String itemName)
          Create a content item with a specific name.
 ContentItem getContentItem(com.jme.scene.Spatial spatial)
          Gets the content item.
 com.jme.scene.Spatial getOrthoRootNode()
          Gets the ortho root node.
 int getScreenHeight()
          Gets the screen height.
 int getScreenWidth()
          Gets the screen width.
 boolean isTopLevelContainer(java.lang.Object item)
          Checks if is top level container.
 void removeAllContentItems()
          Removes the all content items.
 void removeContentItem(ContentItem contentItem)
          Removes the content item.
 void removeContentItem(ContentItem contentItem, boolean releaseTextures)
          Removes the content item.
 void setItemName(ContentItem item, java.lang.String newName)
          Sets the item name.
 void update(float tpf)
          Update.
 
Methods inherited from class synergynetframework.appsystem.contentsystem.ContentSystem
addUpdateableListener, generateUniqueName, getAllContentItems, getContentItem, getContentItemsCount, getContentSystemForSynergyNetApp, getImplementationItemFactory, loadContentItems, removeUpdateableListener
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JMEContentSystem

public JMEContentSystem()
Instantiates a new JME content system.


JMEContentSystem

public JMEContentSystem(com.jme.scene.Node orthoNode)
Instantiates a new JME content system.

Parameters:
orthoNode - the ortho node
Method Detail

addContentItem

public void addContentItem(ContentItem contentItem)
Description copied from class: ContentSystem
Adds the content item.

Specified by:
addContentItem in class ContentSystem
Parameters:
contentItem - the content item

createContentItem

public ContentItem createContentItem(java.lang.Class<? extends ContentItem> contentItemType)
Create a content item where the name will be auto-generated. The content item will be a class that extends ContentItem. You may use the default set of ContentItem classes found in synergynet.contentsystem.items or use your own. If you use your own content item, the content item implementation must live in the same package as the content item.

Specified by:
createContentItem in class ContentSystem
Parameters:
contentItemType - the content item type
Returns:
the content item

createContentItem

public ContentItem createContentItem(java.lang.Class<? extends ContentItem> contentItemType,
                                     java.lang.String itemName)
Create a content item with a specific name. The content item will be a class that extends ContentItem. You may use the default set of ContentItem classes found in synergynet.contentsystem.items or use your own. If you use your own content item, the content item implementation must live in the same package as the content item.

Specified by:
createContentItem in class ContentSystem
Parameters:
contentItemType - the content item type
itemName - the item name
Returns:
the content item

getContentItem

public ContentItem getContentItem(com.jme.scene.Spatial spatial)
Gets the content item.

Parameters:
spatial - the spatial
Returns:
the content item

getOrthoRootNode

public com.jme.scene.Spatial getOrthoRootNode()
Gets the ortho root node.

Returns:
the ortho root node

getScreenHeight

public int getScreenHeight()
Description copied from class: ContentSystem
Gets the screen height.

Specified by:
getScreenHeight in class ContentSystem
Returns:
the screen height

getScreenWidth

public int getScreenWidth()
Description copied from class: ContentSystem
Gets the screen width.

Specified by:
getScreenWidth in class ContentSystem
Returns:
the screen width

isTopLevelContainer

public boolean isTopLevelContainer(java.lang.Object item)
Description copied from class: ContentSystem
Checks if is top level container.

Specified by:
isTopLevelContainer in class ContentSystem
Parameters:
item - the implementation object
Returns:
true, if is top level container

removeAllContentItems

public void removeAllContentItems()
Description copied from class: ContentSystem
Removes the all content items.

Specified by:
removeAllContentItems in class ContentSystem

removeContentItem

public void removeContentItem(ContentItem contentItem)
Description copied from class: ContentSystem
Removes the content item.

Specified by:
removeContentItem in class ContentSystem
Parameters:
contentItem - the content item

removeContentItem

public void removeContentItem(ContentItem contentItem,
                              boolean releaseTextures)
Description copied from class: ContentSystem
Removes the content item.

Specified by:
removeContentItem in class ContentSystem
Parameters:
contentItem - the content item
releaseTextures - the release textures

setItemName

public void setItemName(ContentItem item,
                        java.lang.String newName)
Description copied from class: ContentSystem
Sets the item name.

Specified by:
setItemName in class ContentSystem
Parameters:
item - the item
newName - the name name

update

public void update(float tpf)
Description copied from class: ContentSystem
Update.

Specified by:
update in class ContentSystem
Parameters:
tpf - the tpf