Commit c91c478a authored by Jay Jay Billings's avatar Jay Jay Billings
Browse files

Added cleanup task lists.


Signed-off-by: default avatarJay Jay Billings <billingsjj@ornl.gov>
parent 31aedc36
......@@ -3,16 +3,20 @@
*/
package gov.ornl.rse.renderer;
import java.util.HashMap;
import java.util.Map;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.core.type.TypeReference;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.node.ObjectNode;
/**
*
* TODO: Add tests, documentation, validation, Validator exclusion from JSON, also tags and other features from ICE's Entry, and logging.
*
* Move the Offset and DataFile test classes to the test bundle.
*
* Rename everything to org.eclipse.ice.*
*
* Add license headers, etc.
*
* @author Jay Jay Billings
*
*/
......
......@@ -68,40 +68,6 @@ public class RendererRunner {
osRenderer.setDrawMethod(offsetViewFunc);
osRenderer.setDataElement(sampleOffset);
osRenderer.render();
/**
*/
/**
* -----Ross likes the generic types and wants me to look into generics for
* LitElement
*
* I wrote DataElement to give a json string when toString() is called. This can
* be passed directly to a LitElement component using .setProperty().
*
* I need to try out the DataElements class with LitElement and Vaadin. *
* How about dynamic updates?
*
* -----Ross wants me to see about reflection too
*
* I got data elements working with a tiny bit of reflection. Things we need:
* *DataElement<T> needs to know the Class of the instance of T. This could be
* done on set. *How should DataElement<T> handle null setting? *We need some a
* test to make sure that Jackson reads T in for different types, including the
* Boxed types as well as Pojos.
*
* -----Can we use dependency injection too?
*
* I have tested this with Google Guice. It works fine with javax.* annotations
* and I was able to remove the factory classes entirely. The code is much nicer
* now.
*
* -----Can I show some examples of HTMLView subclasses?
*
* Maybe do it with the LitElement work above.
*
*/
}
private void testSomeStuff() {
......
import {css, customElement, html, LitElement, property} from 'lit-element';
import '@vaadin/vaadin-text-field';
/**
* Tasks:
*
* *Move DataElement<T> to its ts file. It would be really nice to put this in the data structures project since it shadows a class there.
* *Add a unit test?
*/
export class DataElement<T> {
name: string;
description: string;
......@@ -12,6 +20,13 @@ export class DataElement<T> {
}
}
/**
* Tasks:
* *This class should be templated or take a function call back in place of updateDataElement and loadData.
* *Add documentation as required.
* *Remove console debug statements
* *This is just an example so the rest doesn't matter much, (the rest being changing the render() function, etc.).
*/
@customElement("renderer-template")
class Renderer extends LitElement {
......@@ -64,7 +79,9 @@ class Renderer extends LitElement {
console.log(this.dataElement.data);
}
render() {
render() {
// Might clean this up a bit - remove some of the <h2> statements.
return html`
<script>${this.loadData()}</script>
<h1>Greetings ${this.dataElement.name}!</h1>
......@@ -76,7 +93,7 @@ class Renderer extends LitElement {
@input=${this.updateDataElement}
></vaadin-text-field>
</div>
<h2>${this.dataElementJSON}</h2>
<h2>${this.dataElement.description}</h2>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment