func grabEncodeTargets(alg Algorithm, obj interface{}) (interface{}, interface{}, error) {
	var headerObj, payloadObj interface{}

	// get header
	if headerVal := getFieldWithTag(obj, "header"); headerVal != nil {
		headerObj = headerVal.Interface()
	}
	if headerObj == nil {
		headerObj = alg.Header()
	}

	// get payload
	if payloadVal := getFieldWithTag(obj, "payload"); payloadVal != nil {
		payloadObj = payloadVal.Interface()
	}
	if payloadObj == nil {
		payloadObj = obj
	}

	return headerObj, payloadObj, nil
}
func grabEncodeTargets(alg Algorithm, obj interface{}) (interface{}, interface{}, error) {
	var headerObj, payloadObj interface{}

	// get header
	if headerVal := getFieldWithTag(obj, "header"); headerVal != nil {
		headerObj = headerVal.Interface()
	}
	if headerObj == nil {
		headerObj = alg.Header()
	}

	// get payload
	if payloadVal := getFieldWithTag(obj, "payload"); payloadVal != nil {
		payloadObj = payloadVal.Interface()
	}
	if payloadObj == nil {
		payloadObj = obj
	}

	return headerObj, payloadObj, nil
}
func grabEncodeTargets ( alg Algorithm , obj interface { } ) ( interface { } , interface { } , error ) { var headerObj , payloadObj interface { } // get header if headerVal := getFieldWithTag ( obj , " " ) ; headerVal != nil { headerObj = headerVal . Interface ( ) } if headerObj == nil { headerObj = alg . Header ( ) } // get payload if payloadVal := getFieldWithTag ( obj , " " ) ; payloadVal != nil { payloadObj = payloadVal . Interface ( ) } if payloadObj == nil { payloadObj = obj } return headerObj , payloadObj , nil }
// grabEncodeTargets grabs the fields for the obj.
grabEncodeTargets grabs the fields for the obj .