package com.njcn.csharmonic.offline.mincfg.vo;

public class DATA_HARMV //谐波电压含有率
{
	private RTC_Timer time; //数据时标
	private Float[][] HARMV; //3-?谐波电压含有率
	public DATA_HARMV(int num)
	{
		time = new RTC_Timer();
		HARMV = new Float[3][num];
	}
	public static int GetSize(int num)
	{
//C# TO JAVA CONVERTER TODO TASK: There is no Java equivalent to 'sizeof':
		return 6 * Short.SIZE / Byte.SIZE + 3 * num *  Float.SIZE / Byte.SIZE;
	}
	public final boolean SetStructBuf(byte[] bArray, int nHaveRead, int num)
	{
		int nByteSize = bArray.length;
		if (nByteSize < GetSize(num))
		{
			return false;
		}

		int iStep = nHaveRead;
		time.SetStructBuf(bArray, iStep);
		iStep = iStep + RTC_Timer.GetSize();
		RefObject<Float[][]> tempRef_HARMV = new RefObject<Float[][]>(HARMV);
		iStep += Service.convertFloatArrayTwo(bArray, iStep, tempRef_HARMV);
		HARMV = tempRef_HARMV.argvalue;
		return true;
	}
}