package com.mackemlad.sizing.client.data;

public class OrderData {
    private static OrderRecord[] records;  
    
    public static OrderRecord[] getRecords() {  
        if (records == null) {  
            records = getNewRecords();  
        }  
        return records;  
    }  
  
    public static OrderRecord[] getNewRecords() { 
    	float itemACost = (float) 4.5;
    	float itemARetail = 10;
    	float itemAMargin = (1 - (itemACost / itemARetail)) * 100;
    	float itemBCost = (float) 3.5;
    	float itemBRetail = 10;
    	float itemBMargin = (1 - (itemBCost / itemBRetail)) * 100;
        return new OrderRecord[]{  
                new OrderRecord(0, 1, itemACost, itemARetail, itemAMargin),
                new OrderRecord(1, 2, itemBCost, itemBRetail, itemBMargin)  
        };  
    }  

}
