Visit Platform at http://www.platform.com

Platform Symphony 5.1 Java API Reference

com.platform.symphony.soam
Class ResourcePreference

java.lang.Object
  extended by com.platform.symphony.soam.ResourcePreference

public class ResourcePreference
extends java.lang.Object

This object gives the developer the ability to be able to programmatically describe any preference for resources while their workload executes in the cluster. This preference can be associated with sessions or tasks.

NOTE: If any of the methods of this class are called after the main(...) method exits, the client or service process may behave in an undefined manner (for example, hang or terminate abnormally).


Constructor Summary
ResourcePreference()
          Constructs an empty resource preference that can be populated by resource attribute definitions.
ResourcePreference(java.lang.String expression)
          Gives a more complex interface for allowing the developer to construct a string representation of the preference.
 
Method Summary
 void addDefinition(ResourceAttributeDefinition definition)
          Allows a definition to be associated with a preference.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResourcePreference

public ResourcePreference()
Constructs an empty resource preference that can be populated by resource attribute definitions.


ResourcePreference

public ResourcePreference(java.lang.String expression)
Gives a more complex interface for allowing the developer to construct a string representation of the preference. The expression cannot exceed a length of 2048 characters.

NOTE: Refer to "Specifying Resource Preference for Sessions and Tasks" in the Cluster and Application Management guide or to the Data-aware Scheduling User Guide for more details on the preference expression syntax.

Parameters:
expression - The preference expression to be used at evaluation time.
Method Detail

addDefinition

public void addDefinition(ResourceAttributeDefinition definition)
                   throws SoamException
Allows a definition to be associated with a preference. When no explicit expression is specified, an expression will be built automatically by combining all definitions added to the preference. For example : If you added definitions with aliases of "DatasetA" and "DatasetB", the resulting expression will be "DatasetA + DatasetB".

NOTE: Once user explicitly specifies an expression, adding definitions will have no effect on the expression.

Parameters:
definition - [IN] - The definition to be used within this preference when resolving the specified resource attribute
Throws:
SoamException

Version 5.1
Date Modified: -DREL_DATE=Apr 28 2011
Platform Computing. Accelerating Intelligence(TM).
Copyright (C) 2001-2009 Platform Computing Corporation. All rights reserved.