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

java.lang.Object
  extended by org.apache.hadoop.yarn.api.records.ProtoBase<YarnProtos.LocalResourceProto>
      extended by org.apache.hadoop.yarn.api.records.impl.pb.LocalResourcePBImpl
All Implemented Interfaces:
LocalResource

public class LocalResourcePBImpl
extends ProtoBase<YarnProtos.LocalResourceProto>
implements LocalResource


Constructor Summary
LocalResourcePBImpl()
           
LocalResourcePBImpl(YarnProtos.LocalResourceProto proto)
           
 
Method Summary
 YarnProtos.LocalResourceProto getProto()
           
 URL getResource()
          Get the location of the resource to be localized.
 long getSize()
          Get the size of the resource to be localized.
 long getTimestamp()
          Get the original timestamp of the resource to be localized, used for verification.
 LocalResourceType getType()
          Get the LocalResourceType of the resource to be localized.
 LocalResourceVisibility getVisibility()
          Get the LocalResourceVisibility of the resource to be localized.
 void setResource(URL resource)
          Set location of the resource to be localized.
 void setSize(long size)
          Set the size of the resource to be localized.
 void setTimestamp(long timestamp)
          Set the timestamp of the resource to be localized, used for verification.
 void setType(LocalResourceType type)
          Set the LocalResourceType of the resource to be localized.
 void setVisibility(LocalResourceVisibility visibility)
          Set the LocalResourceVisibility of the resource to be localized.
 
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

LocalResourcePBImpl

public LocalResourcePBImpl()

LocalResourcePBImpl

public LocalResourcePBImpl(YarnProtos.LocalResourceProto proto)
Method Detail

getProto

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

getSize

public long getSize()
Description copied from interface: LocalResource
Get the size of the resource to be localized.

Specified by:
getSize in interface LocalResource
Returns:
size of the resource to be localized

setSize

public void setSize(long size)
Description copied from interface: LocalResource
Set the size of the resource to be localized.

Specified by:
setSize in interface LocalResource
Parameters:
size - size of the resource to be localized

getTimestamp

public long getTimestamp()
Description copied from interface: LocalResource
Get the original timestamp of the resource to be localized, used for verification.

Specified by:
getTimestamp in interface LocalResource
Returns:
timestamp of the resource to be localized

setTimestamp

public void setTimestamp(long timestamp)
Description copied from interface: LocalResource
Set the timestamp of the resource to be localized, used for verification.

Specified by:
setTimestamp in interface LocalResource
Parameters:
timestamp - timestamp of the resource to be localized

getType

public LocalResourceType getType()
Description copied from interface: LocalResource
Get the LocalResourceType of the resource to be localized.

Specified by:
getType in interface LocalResource
Returns:
LocalResourceType of the resource to be localized

setType

public void setType(LocalResourceType type)
Description copied from interface: LocalResource
Set the LocalResourceType of the resource to be localized.

Specified by:
setType in interface LocalResource
Parameters:
type - LocalResourceType of the resource to be localized

getResource

public URL getResource()
Description copied from interface: LocalResource
Get the location of the resource to be localized.

Specified by:
getResource in interface LocalResource
Returns:
location of the resource to be localized

setResource

public void setResource(URL resource)
Description copied from interface: LocalResource
Set location of the resource to be localized.

Specified by:
setResource in interface LocalResource
Parameters:
resource - location of the resource to be localized

getVisibility

public LocalResourceVisibility getVisibility()
Description copied from interface: LocalResource
Get the LocalResourceVisibility of the resource to be localized.

Specified by:
getVisibility in interface LocalResource
Returns:
LocalResourceVisibility of the resource to be localized

setVisibility

public void setVisibility(LocalResourceVisibility visibility)
Description copied from interface: LocalResource
Set the LocalResourceVisibility of the resource to be localized.

Specified by:
setVisibility in interface LocalResource
Parameters:
visibility - LocalResourceVisibility of the resource to be localized


Copyright © 2012 Apache Software Foundation. All Rights Reserved.