rename FieldTypeInt to bsiGroupTypeInt

This commit is contained in:
Travis Turner 2018-06-04 15:49:02 -05:00
parent 63e41b912b
commit 5d39ba25df
No known key found for this signature in database
GPG key ID: 7F08008DFD9314C9
2 changed files with 7 additions and 7 deletions

View file

@ -328,7 +328,7 @@ func (f *Frame) applyOptions(opt FrameOptions) error {
// Create new bsiGroup.
bsig := &bsiGroup{
Name: f.name,
Type: FieldTypeInt,
Type: bsiGroupTypeInt,
Min: opt.Min,
Max: opt.Max,
}
@ -1070,14 +1070,14 @@ func decodeFrameOptions(options *internal.FrameMeta) *FrameOptions {
}
}
// List of field data types.
// List of bsiGroup types.
const (
FieldTypeInt = "int"
bsiGroupTypeInt = "int"
)
func IsValidFieldType(v string) bool {
switch v {
case FieldTypeInt:
case bsiGroupTypeInt:
return true
default:
return false

View file

@ -25,20 +25,20 @@ import (
func TestField_BaseValue(t *testing.T) {
b0 := &bsiGroup{
Name: "b0",
Type: FieldTypeInt,
Type: bsiGroupTypeInt,
Min: -100,
Max: 900,
}
b1 := &bsiGroup{
Name: "b1",
Type: FieldTypeInt,
Type: bsiGroupTypeInt,
Min: 0,
Max: 1000,
}
b2 := &bsiGroup{
Name: "b2",
Type: FieldTypeInt,
Type: bsiGroupTypeInt,
Min: 100,
Max: 1100,
}