Skip to content

Commit b829fe2

Browse files
committed
Add valueFormatter to the Builder
1 parent a472286 commit b829fe2

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

Diff for: dygraphs-gwt/src/main/java/com/github/timeu/dygraphsgwt/client/options/AxisOptions.java

+5
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,11 @@ public Builder pixelsPerLabel(int pixelsPerLabel) {
135135
return this;
136136
}
137137

138+
public Builder valueFormatter(ValueFormatter valueFormatter) {
139+
this.options.valueFormatter = valueFormatter;
140+
return this;
141+
}
142+
138143
public AxisOptions build() {
139144
return options;
140145
}

Diff for: dygraphs-gwt/src/main/java/com/github/timeu/dygraphsgwt/client/options/ValueFormatter.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,5 @@ public interface ValueFormatter {
2323
* @param row The row of the data from which this point comes. g.getValue(row, 0) will return the x-value for this point.
2424
* @param col The column of the data from which this point comes. g.getValue(row, col) will return the original y-value for this point. This can be used to get the full confidence interval for the point, or access un-rolled values for the point.
2525
*/
26-
void onValueFormatter(long value,OptFunction opts,String seriesName,DygraphsJs dygraphjs,int row,int col);
26+
String onValueFormatter(long value,OptFunction opts,String seriesName,DygraphsJs dygraphjs,int row,int col);
2727
}

0 commit comments

Comments
 (0)