Skip to content

Commit

Permalink
DDF-2644 Cleaned up todos and some comments (#44)
Browse files Browse the repository at this point in the history
  • Loading branch information
rzwiefel committed Dec 28, 2016
1 parent 27fe563 commit e0165d0
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,6 @@ public void init() {
return util.getJson(validator.validateAttribute(attribute, value));
});

// TODO (RCZ) - this could use some help
get("/history/:id", (req, res) -> {
String id = req.params(":id");
List<Result> queryResponse = getMetacardHistory(id);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,10 @@
import ddf.catalog.data.impl.BasicTypes;
import ddf.catalog.validation.AttributeValidatorRegistry;
import ddf.catalog.validation.violation.ValidationViolation;
import spark.Experimental;

@Experimental // TODO (RCZ) - This is sparks experimental iface, could we use?
/**
* This class is Experimental and subject to change
*/
public class ExperimentalEnumerationExtractor {
private final AttributeValidatorRegistry attributeValidatorRegistry;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,6 @@ public Metacard toMetacardFromXml(Serializable xml) {
}
}
} catch (Exception ex) {
// TODO (RCZ) - just throw?
throw new RuntimeException(ex);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ public Response deleteAttribute(@Context HttpServletResponse response,

if (metacardAttribute == null) {
return Response.ok()
.build(); // TODO (RCZ) - if it wasn't there is that an okay or bad?
.build();
}


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,6 @@ public Map<String, Result> getMetacards(String attributeName, Collection<String>
return results;
}

// TODO (RCZ) - This method could do with some immutable/persistant objects
@SuppressWarnings("unchecked")
public Map<String, Object> getMetacardTypeMap() {
Map<String, Object> resultTypes = new HashMap<>();
Expand Down Expand Up @@ -261,7 +260,6 @@ public Map<String, Object> transformToMap(List<Metacard> metacards) {
typeMap.put("type-name", type);
typeMap.put("type", getMetacardTypeMap().get(type));

// TODO (RCZ) - optimize this since might be hit a lot
typeMap.put("ids",
metacards.stream()
.filter(mc -> type.equals(mc.getMetacardType()
Expand Down

0 comments on commit e0165d0

Please sign in to comment.