Women in Technology

Hear us Roar

  Java Web Development with Stripes
Subject:   Code typo?
Date:   2007-01-25 11:41:14
From:   mjeagle
Response to: Code typo?

Sorry, the field is of type Person and the accessors should look like this:

public void setPerson(Person person) {this.person = person;}

public Person getPerson() { return person;}

Sorry for the confusion.


Full Threads Newest First

Showing messages 1 through 2 of 2.

  • Code typo?
    2007-03-13 22:39:37  keytasks [View]

    I tried the correction - you suggested though I'm getting 'cannot find symbol error' in my IDE editor on the following line of code - as well as the getter and setters

    private Person person;

    The article looks great - I'm hoping to get the article working with Spring1.4.2 with NetBeans5.5

    Thanks Derek

    • Code typo?
      2007-03-14 05:46:50  mjeagle [View]

      Here is the code for the Person class:

      package com.meagle.blog.domain;

      * Simple Person object
      * User: meagle
      * Date: Jan 7, 2007
      * Time: 8:55:47 PM
      public class Person {

      private int id;
      private String firstName;
      private Integer age;

      public int getId() {
      return id;

      public void setId(int id) {
      this.id = id;

      public String getFirstName() {
      return firstName;

      public void setFirstName(String firstName) {
      this.firstName = firstName;

      public Integer getAge() {
      return age;

      public void setAge(Integer age) {
      this.age = age;