org.apache.hadoop.yarn.api.records.impl.pb
Class ContainerLaunchContextPBImpl

java.lang.Object
  extended by org.apache.hadoop.yarn.api.records.ProtoBase<YarnProtos.ContainerLaunchContextProto>
      extended by org.apache.hadoop.yarn.api.records.impl.pb.ContainerLaunchContextPBImpl
All Implemented Interfaces:
ContainerLaunchContext

public class ContainerLaunchContextPBImpl
extends ProtoBase<YarnProtos.ContainerLaunchContextProto>
implements ContainerLaunchContext


Constructor Summary
ContainerLaunchContextPBImpl()
           
ContainerLaunchContextPBImpl(YarnProtos.ContainerLaunchContextProto proto)
           
 
Method Summary
 Map<ApplicationAccessType,String> getApplicationACLs()
          Get the ApplicationACLs for the application.
 List<String> getCommands()
          Get the list of commands for launching the container.
 ContainerId getContainerId()
          Get ContainerId of container to be launched.
 ByteBuffer getContainerTokens()
          Get security tokens (if security is enabled).
 Map<String,String> getEnvironment()
          Get environment variables for the container.
 Map<String,LocalResource> getLocalResources()
          Get LocalResource required by the container.
 YarnProtos.ContainerLaunchContextProto getProto()
           
 Resource getResource()
          Get the Resource allocated to the container by the ResourceManager.
 Map<String,ByteBuffer> getServiceData()
          Get application-specific binary service data.
 String getUser()
          Get the user to whom the container has been allocated.
 void setApplicationACLs(Map<ApplicationAccessType,String> appACLs)
          Set the ApplicationACLs for the application.
 void setCommands(List<String> commands)
          Add the list of commands for launching the container.
 void setContainerId(ContainerId containerId)
          Set ContainerId of container to be launched.
 void setContainerTokens(ByteBuffer containerTokens)
          Set security tokens (if security is enabled).
 void setEnvironment(Map<String,String> env)
          Add environment variables for the container.
 void setLocalResources(Map<String,LocalResource> localResources)
          Set LocalResource required by the container.
 void setResource(Resource resource)
          Set the Resource allocated to the container by the ResourceManager.
 void setServiceData(Map<String,ByteBuffer> serviceData)
          Set application-specific binary service data.
 void setUser(String user)
          Set the user to whom the container has been allocated
 
Methods inherited from class org.apache.hadoop.yarn.api.records.ProtoBase
convertFromProtoFormat, convertToProtoFormat, equals, hashCode, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ContainerLaunchContextPBImpl

public ContainerLaunchContextPBImpl()

ContainerLaunchContextPBImpl

public ContainerLaunchContextPBImpl(YarnProtos.ContainerLaunchContextProto proto)
Method Detail

getProto

public YarnProtos.ContainerLaunchContextProto getProto()
Specified by:
getProto in class ProtoBase<YarnProtos.ContainerLaunchContextProto>

getResource

public Resource getResource()
Description copied from interface: ContainerLaunchContext
Get the Resource allocated to the container by the ResourceManager.

Specified by:
getResource in interface ContainerLaunchContext
Returns:
Resource allocated to the container by the ResourceManager

setResource

public void setResource(Resource resource)
Description copied from interface: ContainerLaunchContext
Set the Resource allocated to the container by the ResourceManager.

Specified by:
setResource in interface ContainerLaunchContext
Parameters:
resource - allocated resource

getCommands

public List<String> getCommands()
Description copied from interface: ContainerLaunchContext
Get the list of commands for launching the container.

Specified by:
getCommands in interface ContainerLaunchContext
Returns:
the list of commands for launching the container

setCommands

public void setCommands(List<String> commands)
Description copied from interface: ContainerLaunchContext
Add the list of commands for launching the container. All pre-existing List entries are cleared before adding the new List

Specified by:
setCommands in interface ContainerLaunchContext
Parameters:
commands - the list of commands for launching the container

getUser

public String getUser()
Description copied from interface: ContainerLaunchContext
Get the user to whom the container has been allocated.

Specified by:
getUser in interface ContainerLaunchContext
Returns:
the user to whom the container has been allocated

setUser

public void setUser(String user)
Description copied from interface: ContainerLaunchContext
Set the user to whom the container has been allocated

Specified by:
setUser in interface ContainerLaunchContext
Parameters:
user - user to whom the container has been allocated

getContainerId

public ContainerId getContainerId()
Description copied from interface: ContainerLaunchContext
Get ContainerId of container to be launched.

Specified by:
getContainerId in interface ContainerLaunchContext
Returns:
ContainerId of container to be launched

setContainerId

public void setContainerId(ContainerId containerId)
Description copied from interface: ContainerLaunchContext
Set ContainerId of container to be launched.

Specified by:
setContainerId in interface ContainerLaunchContext
Parameters:
containerId - et ContainerId of container to be launched

getLocalResources

public Map<String,LocalResource> getLocalResources()
Description copied from interface: ContainerLaunchContext
Get LocalResource required by the container.

Specified by:
getLocalResources in interface ContainerLaunchContext
Returns:
all LocalResource required by the container

setLocalResources

public void setLocalResources(Map<String,LocalResource> localResources)
Description copied from interface: ContainerLaunchContext
Set LocalResource required by the container. All pre-existing Map entries are cleared before adding the new Map

Specified by:
setLocalResources in interface ContainerLaunchContext
Parameters:
localResources - LocalResource required by the container

getContainerTokens

public ByteBuffer getContainerTokens()
Description copied from interface: ContainerLaunchContext
Get security tokens (if security is enabled).

Specified by:
getContainerTokens in interface ContainerLaunchContext
Returns:
security tokens (if security is enabled)

setContainerTokens

public void setContainerTokens(ByteBuffer containerTokens)
Description copied from interface: ContainerLaunchContext
Set security tokens (if security is enabled).

Specified by:
setContainerTokens in interface ContainerLaunchContext
Parameters:
containerTokens - security tokens

getServiceData

public Map<String,ByteBuffer> getServiceData()
Description copied from interface: ContainerLaunchContext
Get application-specific binary service data.

Specified by:
getServiceData in interface ContainerLaunchContext
Returns:
application-specific binary service data

setServiceData

public void setServiceData(Map<String,ByteBuffer> serviceData)
Description copied from interface: ContainerLaunchContext
Set application-specific binary service data. All pre-existing Map entries are preserved.

Specified by:
setServiceData in interface ContainerLaunchContext
Parameters:
serviceData - application-specific binary service data

getEnvironment

public Map<String,String> getEnvironment()
Description copied from interface: ContainerLaunchContext
Get environment variables for the container.

Specified by:
getEnvironment in interface ContainerLaunchContext
Returns:
environment variables for the container

setEnvironment

public void setEnvironment(Map<String,String> env)
Description copied from interface: ContainerLaunchContext
Add environment variables for the container. All pre-existing Map entries are cleared before adding the new Map

Specified by:
setEnvironment in interface ContainerLaunchContext
Parameters:
env - environment variables for the container

getApplicationACLs

public Map<ApplicationAccessType,String> getApplicationACLs()
Description copied from interface: ContainerLaunchContext
Get the ApplicationACLs for the application.

Specified by:
getApplicationACLs in interface ContainerLaunchContext
Returns:
all the ApplicationACLs

setApplicationACLs

public void setApplicationACLs(Map<ApplicationAccessType,String> appACLs)
Description copied from interface: ContainerLaunchContext
Set the ApplicationACLs for the application. All pre-existing Map entries are cleared before adding the new Map

Specified by:
setApplicationACLs in interface ContainerLaunchContext
Parameters:
appACLs - ApplicationACLs for the application


Copyright © 2012 Apache Software Foundation. All Rights Reserved.