// Decompiled by Jad v1.5.8e. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/kpdus/jad.html
// Decompiler options: packimports(3) 
// Source File Name:   TLeafF.java

package hep.rootio.reps;

import hep.rootio.RootInput;
import hep.rootio.implementation.*;

import java.io.DataInput;
import java.io.IOException;

// Referenced classes of package hep.rootio.reps:
//            TLeafI, TBranch

public class TLeafF extends SpecificRootObject
    implements Leaf
{

    public TLeafF()
    {
        curIndex = -1;
    }

    public Object readData(RootInput in, int index)
        throws IOException
    {
        TLeafI count = (TLeafI)get("fLeafCount");
        Object length = count != null ? count.getValue(index) : get("fLen");
        int len = ((Integer)length).intValue();
        if(count == null && len == 1)
            return new Float(in.readFloat());
        float result[] = new float[len];
        for(int i = 0; i < len; i++)
            result[i] = in.readFloat();

        return result;
    }

    public void setBranch(TBranch tbranch)
    {
    }

    private int curIndex;
    private Object curValue;
}

 

Ads help maintain this website.