khushi2012's Profile User Rating: -----

Reputation: 0 Apprentice
Group:
Members
Active Posts:
28 (0.06 per day)
Joined:
03-January 12
Profile Views:
166
Last Active:
User is offline Jan 11 2012 03:36 PM
Currently:
Offline

Previous Fields

Dream Kudos:
0
Icon   khushi2012 has not set their status

Posts I've Made

  1. In Topic: Airline Reservation System

    Posted 11 Jan 2012

    Hey guys.. I solved my problem.. N guess what I am done with my project :)
    M so happy. Thanks everyone a lot n especially #36 macosxnerd101
  2. In Topic: Airline Reservation System

    Posted 10 Jan 2012

    I have written above :(
  3. In Topic: Airline Reservation System

    Posted 10 Jan 2012

    View Postpbl, on 10 January 2012 - 11:31 PM, said:

    You have it defined twice

        public void setSeats(String[] y)
        {
            seats = y;
        }
        public void setSeats(String[] seats)
        {
            this.seats = seats;
        }
    
    



    ya i said sorry..exclude lines 44 to 47
  4. In Topic: Airline Reservation System

    Posted 10 Jan 2012

    import java.io.Serializable;
    
    import java.io.*;
    import java.util.*;
    
    public class Flights implements Serializable 
    {
    	
    	private String fno;
    	private String source;
    	private String dest;
    	private String day;
    	private String time;
    	private String tos;
    	private String seats[];
    	private String cost;
    	private String z[];
    	
    	
    	public Flights(String fno, String source, String dest, String day, String time, String tos, String cost, String[] z)
    	{
    		this.fno = fno;
    		this.source = source;
    		this.dest = dest;
    		this.day = day;
    		this.time = time;
    		this.tos = tos;
    		this.cost = cost;
    		int b = Integer.parseInt(tos);
    		String seats[]=new String[b];
    		for(int i=0; i<b ; i++)
    		{
    			seats[i]= "n";
     		}
    		this.z = z;
    	}
    
    	public void setSeats(String[] y)
    	{
    		seats = y;
    	}
    	
    
    	public void setSeats(String[] seats)
    	{
    		this.seats = seats;
    	}
    
    	public String getFno() 
    	{
    		return fno;
    	}
    
    
    	public String getSource() 
    	{
    		return source;
    	}
    
    
    	public String getDest() 
    	{
    		return dest;
    	}
    
    
    	public String getDay() 
    	{
    		return day;
    	}
    
    	public String getTime() 
    	{
    		return time;
    	}
    
    
    	public String getTos() 
    	{
    		return tos;
    	}
    
    
    	public String getCost() 
    	{
    		return cost;
    	}
    
    	public String[] getSeats()
    	{
    		return seats;
    	}
    
    	public String[] getD()
    	{
    		return z;
    	}
    	
    }
    

    Whats wrong with this code??
    this portion is not giving any error as such
    
    	public void setSeats(String[] y)
    	{
    		seats = y;
    	}
    
    


    but by including this...
    list = (ArrayList<Flights>)oin.readObject();
    
    
    has stopped working.

    sorry lines 44 to 47 should not be considered.
  5. In Topic: Airline Reservation System

    Posted 9 Jan 2012

    The problem is solved.. I made the variable j and method getIndex static.
    So i dun have to create an object to use getIndex.

My Information

Member Title:
New D.I.C Head
Age:
Age Unknown
Birthday:
Birthday Unknown
Gender:

Contact Information

E-mail:
Private

Friends

khushi2012 hasn't added any friends yet.

Comments

khushi2012 has no profile comments yet. Why not say hello?