• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

can I add Vectors together?

 
Zoe Peng
Ranch Hand
Posts: 112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have three vectors in my databean. My question is how can I make addressVector is equal to all the cityVector+ stateVector?
I got convert Vector to int error.
Thanks.
Vector addressVector = this.getAddressList();
Vector cityVector = this.getCityList();
vector stateVector = this.getStateList();
public Vector getAddressList(){return addressList; }
public Vector getCity(){return cityList; }
public Vector getStateList(){return stateList; }
public void setAddressList(Vector arg) { addressList = arg; }
public void setCityList(Vector arg) { cityList = arg; }
public void setStateList(Vector arg) { stateList = arg; }

 
Kris Nelson
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm assuming that addressList, cityList and stateList are data members of this class. What type/class are they declared as?

------------------
WebNelly.com
Java/XML Web Development
Check it out!
http://www.webnelly.com
 
Zoe Peng
Ranch Hand
Posts: 112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
it's String.
is addAll method can fix this problem?
Thanks
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic