You are viewing a plain text version of this content. The canonical link for it is here.
Posted to taglibs-user@tomcat.apache.org by "Dinesh, S." <di...@golisa.com> on 2001/11/21 03:02:22 UTC

Custom Tag - Error Compiling

Hi All,

I am playing around with Custom Tags. I have a Table Tag that extends a
FieldTag. Compiling the FieldTag works fine, however, everytime I compile
the TableTag, I keep getting the following:-

Superclass com.jcs.db.dbase.FieldTag of class com.jcs.db.dbase.TableTag not
found.
public class TableTag extends FieldTag {
                              ^
1 error

I know I am doing something wrong somewhere, but I just can't figure out
what. Can anyone kindly advice? My code follows below.

Thank you in Advance.
Dinesh, S.



FieldTag.java
----------------------------------------------------------------------------
----
package com.jcs.db.dbase;
import javax.servlet.jsp.JspException;
import javax.servlet.jsp.tagext.*;

public class FieldTag extends TagSupport {
  private String _name = null;

  public void setName(String name)

    _name = name;
  }
  public String getName()

    return _name;
  }
  public int doStartTag() throws
ax.servlet.jsp.JspTagException{ 
    return EVAL_BODY_INCLUDE; 
  } 
  public void release() {
    _name = null;
  }
} 
--------------------------------------------------------------------------------

TableTag.java
--------------------------------------------------------------------------------
package com.jcs.db.dbase;
public class TableTag extends FieldTag {
  public TableTag() {
    setName("Hello");
  }
}
--------------------------------------------------------------------------------


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Custom Tag - Error Compiling

Posted by Ritesh <ri...@telconindia.com>.
HI Dinesh,

I think u should import your package in the table Tag file. Sometime the
probleb get solved from it.

Ritesh Agarwal
----- Original Message -----
From: "Dinesh, S." <di...@golisa.com>
To: <ta...@jakarta.apache.org>
Sent: Wednesday, November 21, 2001 7:32 AM
Subject: Custom Tag - Error Compiling


> Hi All,
>
> I am playing around with Custom Tags. I have a Table Tag that extends a
> FieldTag. Compiling the FieldTag works fine, however, everytime I compile
> the TableTag, I keep getting the following:-
>
> Superclass com.jcs.db.dbase.FieldTag of class com.jcs.db.dbase.TableTag
not
> found.
> public class TableTag extends FieldTag {
>                               ^
> 1 error
>
> I know I am doing something wrong somewhere, but I just can't figure out
> what. Can anyone kindly advice? My code follows below.
>
> Thank you in Advance.
> Dinesh, S.
>
>
>
> FieldTag.java
> --------------------------------------------------------------------------
--
> ----
> package com.jcs.db.dbase;
> import javax.servlet.jsp.JspException;
> import javax.servlet.jsp.tagext.*;
>
> public class FieldTag extends TagSupport {
>   private String _name = null;
>
>   public void setName(String name)
>
>     _name = name;
>   }
>   public String getName()
>
>     return _name;
>   }
>   public int doStartTag() throws
> ax.servlet.jsp.JspTagException{
>     return EVAL_BODY_INCLUDE;
>   }
>   public void release() {
>     _name = null;
>   }
> }
> --------------------------------------------------------------------------
------
>
> TableTag.java
> --------------------------------------------------------------------------
------
> package com.jcs.db.dbase;
> public class TableTag extends FieldTag {
>   public TableTag() {
>     setName("Hello");
>   }
> }
> --------------------------------------------------------------------------
------
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: Custom Tag - Error Compiling

Posted by "Dinesh, S." <di...@golisa.com>.
Hi All,

The problem is solved. Silly me, apparently I did not have the servlet.jar
in my classpath.

Thank you for all the advice and assistance.
Dinesh, S.



-----Original Message-----
From: Dinesh, S. [mailto:dinesh@golisa.com]
Sent: Wednesday, November 21, 2001 9:02 AM
To: taglibs-user@jakarta.apache.org
Subject: Custom Tag - Error Compiling


Hi All,

I am playing around with Custom Tags. I have a Table Tag that extends a
FieldTag. Compiling the FieldTag works fine, however, everytime I compile
the TableTag, I keep getting the following:-

Superclass com.jcs.db.dbase.FieldTag of class com.jcs.db.dbase.TableTag not
found.
public class TableTag extends FieldTag {
                              ^
1 error

I know I am doing something wrong somewhere, but I just can't figure out
what. Can anyone kindly advice? My code follows below.

Thank you in Advance.
Dinesh, S.


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>