edu.internet2.middleware.ant.util
Class StringFromFile

java.lang.Object
  extended by org.apache.tools.ant.ProjectComponent
      extended by org.apache.tools.ant.Task
          extended by edu.internet2.middleware.ant.util.StringFromFile
All Implemented Interfaces:
Cloneable

public class StringFromFile
extends org.apache.tools.ant.Task

Ant task that makes the contents of a file available as a property. This ant task requires two attributes:


Field Summary
private  String addProperty
          Property name to which the file contents are added.
private  File input
          The input file.
 
Fields inherited from class org.apache.tools.ant.Task
target, taskName, taskType, wrapper
 
Fields inherited from class org.apache.tools.ant.ProjectComponent
description, location, project
 
Constructor Summary
StringFromFile()
           
 
Method Summary
 void execute()
          
 void setAddProperty(String prop)
          Sets the property name to which the file contents are added.
 void setInput(File f)
          Sets the file from which the data will be read.
 
Methods inherited from class org.apache.tools.ant.Task
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
 
Methods inherited from class org.apache.tools.ant.ProjectComponent
clone, getDescription, getLocation, getProject, setDescription, setLocation, setProject
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

input

private File input
The input file.


addProperty

private String addProperty
Property name to which the file contents are added.

Constructor Detail

StringFromFile

public StringFromFile()
Method Detail

execute

public void execute()

Overrides:
execute in class org.apache.tools.ant.Task

setInput

public void setInput(File f)
Sets the file from which the data will be read.

Parameters:
f - file from which the data will be read

setAddProperty

public void setAddProperty(String prop)
Sets the property name to which the file contents are added.

Parameters:
prop - property name to which the file contents are added.


Copyright © 1999-2014. All Rights Reserved.