gr.uoa.di.madgik.commons.infra.nodeassignmentpolicy
Class MaximumCollocationPolicy

java.lang.Object
  extended by gr.uoa.di.madgik.commons.infra.nodeassignmentpolicy.MaximumCollocationPolicy
All Implemented Interfaces:
NodeAssignmentPolicy

public class MaximumCollocationPolicy
extends Object
implements NodeAssignmentPolicy

This policy tries to assign as many functional plan elements of the same plan as possible to the same boundary. Conversely, the policy will attempt to spread functional plan elements of different plans to different boundaries.

Author:
gerasimos.farantatos - DI NKUA

Nested Class Summary
 
Nested classes/interfaces inherited from interface gr.uoa.di.madgik.commons.infra.nodeassignmentpolicy.NodeAssignmentPolicy
NodeAssignmentPolicy.Type
 
Field Summary
static float DefaultPenalty
           
 
Constructor Summary
MaximumCollocationPolicy(NodeSelector selector)
           
MaximumCollocationPolicy(NodeSelector selector, float threshold)
           
MaximumCollocationPolicy(NodeSelector selector, Float threshold)
           
 
Method Summary
 float getCommitFactor(HostingNode hn)
           
 NodeAssignmentPolicy.Type getType()
           
 void reset()
           
 HostingNode selectNode(List<HostingNode> candidates)
           
 void setPenalty(float collocationPenalty)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DefaultPenalty

public static float DefaultPenalty
Constructor Detail

MaximumCollocationPolicy

public MaximumCollocationPolicy(NodeSelector selector)

MaximumCollocationPolicy

public MaximumCollocationPolicy(NodeSelector selector,
                                Float threshold)

MaximumCollocationPolicy

public MaximumCollocationPolicy(NodeSelector selector,
                                float threshold)
Method Detail

getType

public NodeAssignmentPolicy.Type getType()
Specified by:
getType in interface NodeAssignmentPolicy

setPenalty

public void setPenalty(float collocationPenalty)
Specified by:
setPenalty in interface NodeAssignmentPolicy

selectNode

public HostingNode selectNode(List<HostingNode> candidates)
                       throws Exception
Specified by:
selectNode in interface NodeAssignmentPolicy
Throws:
Exception

getCommitFactor

public float getCommitFactor(HostingNode hn)
                      throws Exception
Throws:
Exception

reset

public void reset()
Specified by:
reset in interface NodeAssignmentPolicy


Copyright © 2013. All Rights Reserved.