org.apache.ivy.plugins.trigger

Class LogTrigger

public class LogTrigger extends AbstractTrigger

A trigger performing logging.

The implementation is widely inspired by Ant Echo task.

Method Summary
protected voidlog(String message)
Logs the given message.
voidprogress(IvyEvent event)
voidsetAppend(boolean append)
If true, append to existing file.
voidsetEncoding(String encoding)
Declare the encoding to use when outputting to a file; Use "" for the platform's default encoding.
voidsetFile(File file)
File to write to.
voidsetMessage(String msg)
Message to write.

Method Detail

log

protected void log(String message)
Logs the given message.

Parameters: message the message to log

progress

public void progress(IvyEvent event)

setAppend

public void setAppend(boolean append)
If true, append to existing file.

Parameters: append if true, append to existing file, default is false.

setEncoding

public void setEncoding(String encoding)
Declare the encoding to use when outputting to a file; Use "" for the platform's default encoding.

Parameters: encoding the character encoding to use.

setFile

public void setFile(File file)
File to write to.

Parameters: file the file to write to, if not set, echo to standard Ivy logging

setMessage

public void setMessage(String msg)
Message to write.

Parameters: msg Sets the value for the message variable.