本文整理汇总了Java中com.github.mikephil.charting.formatter.DefaultValueFormatter类的典型用法代码示例。如果您正苦于以下问题:Java DefaultValueFormatter类的具体用法?Java DefaultValueFormatter怎么用?Java DefaultValueFormatter使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
DefaultValueFormatter类属于com.github.mikephil.charting.formatter包,在下文中一共展示了DefaultValueFormatter类的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: calculateFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
/**
* calculates the required number of digits for the values that might be
* drawn in the chart (if enabled), and creates the default-value-formatter
*/
protected void calculateFormatter(float min, float max) {
float reference = 0f;
if (mData == null || mData.getXValCount() < 2) {
reference = Math.max(Math.abs(min), Math.abs(max));
} else {
reference = Math.abs(max - min);
}
int digits = Utils.getDecimals(reference);
mDefaultFormatter = new DefaultValueFormatter(digits);
}
开发者ID:rahulmaddineni,项目名称:Stayfit,代码行数:19,代码来源:Chart.java
示例2: needsDefaultFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
/**
* If this component has no ValueFormatter or is only equipped with the
* default one (no custom set), return true.
*
* @return
*/
public static boolean needsDefaultFormatter(ValueFormatter formatter) {
if (formatter == null)
return true;
if (formatter instanceof DefaultValueFormatter)
return true;
return false;
}
开发者ID:rahulmaddineni,项目名称:Stayfit,代码行数:15,代码来源:Utils.java
示例3: needsDefaultFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
/**
* If this component has no YAxisValueFormatter or is only equipped with the default one (no custom set), return true.
*
* @return
*/
public boolean needsDefaultFormatter() {
if (mYAxisValueFormatter == null)
return true;
if (mYAxisValueFormatter instanceof DefaultValueFormatter)
return true;
return false;
}
开发者ID:rahulmaddineni,项目名称:Stayfit,代码行数:14,代码来源:YAxis.java
示例4: needsDefaultFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
/**
* If this component has no YAxisValueFormatter or is only equipped with the default one (no
* custom set), return true.
*
* @return
*/
public boolean needsDefaultFormatter() {
if (mYAxisValueFormatter == null)
return true;
if (mYAxisValueFormatter instanceof DefaultValueFormatter)
return true;
return false;
}
开发者ID:pencil-box,项目名称:NetKnight,代码行数:15,代码来源:YAxis.java
示例5: needsDefaultFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
/**
* If this component has no ValueFormatter or is only equipped with the
* default one (no custom set), return true.
*
* @return
*/
public boolean needsDefaultFormatter() {
if (mValueFormatter == null)
return true;
if (mValueFormatter instanceof DefaultValueFormatter)
return true;
return false;
}
开发者ID:xinpengfei520,项目名称:P2P,代码行数:15,代码来源:DataSet.java
示例6: needsDefaultFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
/**
* If this component has no YAxisValueFormatter or is only equipped with the default one (no custom set), return true.
*
* @return
*/
public boolean needsDefaultFormatter() {
if (mYAxisValueFormatter == null)
return true;
if (mYAxisValueFormatter instanceof DefaultValueFormatter)
return true;
return false;
}
开发者ID:xinpengfei520,项目名称:P2P,代码行数:14,代码来源:YAxis.java
示例7: needsDefaultFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
/**
* If this component has no ValueFormatter or is only equipped with the
* default one (no custom set), return true.
*
* @return
*/
public static boolean needsDefaultFormatter(ValueFormatter formatter) {
if (formatter == null)
return true;
return formatter instanceof DefaultValueFormatter;
}
开发者ID:muyoumumumu,项目名称:QuShuChe,代码行数:13,代码来源:Utils.java
示例8: needsDefaultFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
/**
* If this component has no YAxisValueFormatter or is only equipped with the default one (no
* custom set), return true.
*
* @return
*/
public boolean needsDefaultFormatter() {
if (mYAxisValueFormatter == null)
return true;
return mYAxisValueFormatter instanceof DefaultValueFormatter;
}
开发者ID:muyoumumumu,项目名称:QuShuChe,代码行数:13,代码来源:YAxis.java
示例9: generateDefaultValueFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
private static IValueFormatter generateDefaultValueFormatter() {
final DefaultValueFormatter formatter = new DefaultValueFormatter(1);
return formatter;
}
开发者ID:weiwenqiang,项目名称:GitHub,代码行数:5,代码来源:Utils.java
示例10: getValueFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
@Override
public ValueFormatter getValueFormatter() {
if (mValueFormatter == null)
return new DefaultValueFormatter(1);
return mValueFormatter;
}
开发者ID:rahulmaddineni,项目名称:Stayfit,代码行数:7,代码来源:BaseDataSet.java
示例11: getValueFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
/**
* Returns the formatter used for drawing the values inside the chart.
*
* @return
*/
public ValueFormatter getValueFormatter() {
if (mValueFormatter == null)
return new DefaultValueFormatter(1);
return mValueFormatter;
}
开发者ID:xinpengfei520,项目名称:P2P,代码行数:11,代码来源:DataSet.java
示例12: getValueFormatter
import com.github.mikephil.charting.formatter.DefaultValueFormatter; //导入依赖的package包/类
@Override
public ValueFormatter getValueFormatter() {
if (needsFormatter())
return new DefaultValueFormatter(1);
return mValueFormatter;
}
开发者ID:letolab,项目名称:LETO-Toggl_Android,代码行数:7,代码来源:BaseDataSet.java
注:本文中的com.github.mikephil.charting.formatter.DefaultValueFormatter类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论