Skip to content

Commit

Permalink
exported GetObjectByIdent
Browse files Browse the repository at this point in the history
  • Loading branch information
asap2Go committed Nov 14, 2022
1 parent c8debf1 commit 212bba8
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
1 change: 0 additions & 1 deletion a2l/record_layout.go
Original file line number Diff line number Diff line change
Expand Up @@ -963,7 +963,6 @@ forLooP:
} else {
break forLooP
}

}
return absPos, err
}
Expand Down
2 changes: 1 addition & 1 deletion calib_data_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ func TestReadCalibration(t *testing.T) {
log.Warn().Msg("time for parsing test files: " + fmt.Sprint(elapsed.Milliseconds()))
startTime := time.Now()
//find object in a2l struct
obj := cd.getObjectByIdent("ASAM.M.MATRIX_DIM_8_4_2.UBYTE.IDENTICAL")
obj := cd.GetObjectByIdent("ASAM.M.MATRIX_DIM_8_4_2.UBYTE.IDENTICAL")
if len(obj) == 0 {
t.Fatalf("unable to find known identifier")
}
Expand Down
4 changes: 2 additions & 2 deletions record_manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,9 @@ func (cd *CalibrationData) getRecordLayout(c *a2l.Characteristic) (*a2l.RecordLa
return &rl, nil
}

// getObjectByIdent returns an object with a given identifier that is defined within the a2l
// GetObjectByIdent returns an object with a given identifier that is defined within the a2l
// not all datastructures are checked. Only the most relevant ones
func (cd *CalibrationData) getObjectByIdent(ident string) []interface{} {
func (cd *CalibrationData) GetObjectByIdent(ident string) []interface{} {
var calibrationObjects []interface{}
var buf interface{}
var exists bool
Expand Down

0 comments on commit 212bba8

Please sign in to comment.