internal EnumReflectionSensor(ReflectionSensorInfo reflectionSensorInfo) : base(reflectionSensorInfo, GetEnumObservationSize(reflectionSensorInfo.GetMemberType())) { var memberType = reflectionSensorInfo.GetMemberType(); m_Values = Enum.GetValues(memberType); m_IsFlags = memberType.IsDefined(typeof(FlagsAttribute), false); }
public ReflectionSensorBase(ReflectionSensorInfo reflectionSensorInfo, int size) { m_Object = reflectionSensorInfo.Object; m_FieldInfo = reflectionSensorInfo.FieldInfo; m_PropertyInfo = reflectionSensorInfo.PropertyInfo; m_ObservableAttribute = reflectionSensorInfo.ObservableAttribute; m_SensorName = reflectionSensorInfo.SensorName; m_Shape = new[] { size }; }
public ReflectionSensorBase(ReflectionSensorInfo reflectionSensorInfo, int size) { m_Object = reflectionSensorInfo.Object; m_FieldInfo = reflectionSensorInfo.FieldInfo; m_PropertyInfo = reflectionSensorInfo.PropertyInfo; m_ObservableAttribute = reflectionSensorInfo.ObservableAttribute; m_SensorName = reflectionSensorInfo.SensorName; m_ObservationSpec = ObservationSpec.Vector(size); m_NumFloats = size; }