import helloWorld.*;
import org.omg.CORBA.*;

public class GoodDayImpl 
    extends GoodDayPOA
{
    private String location;

    // constructor
    public GoodDayImpl( String location ) 
    {
	// initialize location
        this.location = location;
    }

    // method
    public myStruct[] helloStruct() 
    {
        try {
            myStruct[] sa = new myStruct[2];
            myStruct s = new myStruct();
            s.a_string = "Hello World, from " + location;
            s.a_long = 183920;
            sa[0] = s;

            s = new myStruct();
            s.a_string = "Matei";
            s.a_long = 123;
            sa[1] = s;
            return sa;
        }
        catch (Exception e) {
            e.printStackTrace();
            return new myStruct[0];
        }
    }
}
