use of com.thoughtworks.go.domain.materials.ModifiedAction in project gocd by gocd.
the class SvnLogXmlParser method parseLogEntry.
private Modification parseLogEntry(Element logEntry, String path) throws ParseException {
Element logEntryPaths = logEntry.getChild("paths");
if (logEntryPaths == null) {
/* Path-based access control forbids us from learning
* details of this log entry, so skip it. */
return null;
}
Date modifiedTime = convertDate(logEntry.getChildText("date"));
String author = logEntry.getChildText("author");
String comment = logEntry.getChildText("msg");
String revision = logEntry.getAttributeValue("revision");
Modification modification = new Modification(author, comment, null, modifiedTime, revision);
List paths = logEntryPaths.getChildren("path");
for (Iterator iterator = paths.iterator(); iterator.hasNext(); ) {
Element node = (Element) iterator.next();
if (underPath(path, node.getText())) {
ModifiedAction action = convertAction(node.getAttributeValue("action"));
modification.createModifiedFile(node.getText(), null, action);
}
}
return modification;
}
use of com.thoughtworks.go.domain.materials.ModifiedAction in project gocd by gocd.
the class ModifiedActionTypeHandlerCallback method setParameter.
public void setParameter(ParameterSetter parameterSetter, Object parameter) throws SQLException {
ModifiedAction modifiedAction = (ModifiedAction) parameter;
parameterSetter.setString(modifiedAction.toString());
}
Aggregations