Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 568859
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T13:14:00+00:00 2026-05-13T13:14:00+00:00

pardon my terminology. I’m trying to use three jar files with a java program

  • 0

pardon my terminology. I’m trying to use three jar files with a java program for my CS class. The first is funjava, a simplified java language, and the others are class definitions color and geometry. Here is my code and what happens when I try to run it.

import colors.*;

class Canvas{

 public static void main(String [] args){
  System.out.println("test123"); 

  Circle cr1 = new Circle( new Posn(1,2), 5, "blue");
  Circle cr2 = new Circle( new Posn(5,4), 3, "red");
 }

}

class  Circle{

 Posn center;
 int rad;
 String color;

 Circle(Posn p, int r, String c){
  this.center = p;
  this.rad = r;
  this.color = c;  
 }

}

class Posn{

 int x;
 int y;

 Posn(int x, int y){
  this.x = x;
  this.y = y;  
 }

}

The last argument of Circle should be a color from the colors.jar, not a string.

niko@niko-laptop:~/Classes/Fundies2$ javac -cp *.jar Canvas.java 
error: Class names, 'funjava.jar,geometry.jar', are only accepted if annotation processing is explicitly requested
1 error
niko@niko-laptop:~/Classes/Fundies2$ ls
1-20-10.java  1-21-10.java  Book.class  Canvas.class  Circle.java  Examples.class  funjava.jar   hw1~        Main.java    OceanWorld.java
1-21-10       Author.class  book.java   Canvas.java   colors.jar   Examples.java   geometry.jar  Ishape      OceanWorld   Posn.class
1-21-10~      Author.java   Book.java   Circle.class  Combo.java   Fundies2.txt    hw1           Main.class  OceanWorld~  Rect.java

So how do I explicitly request annotation processing?
Thank you.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T13:14:00+00:00Added an answer on May 13, 2026 at 1:14 pm

    In addition to Romain Muller‘s answer:

    If you want to quickly use all of the *.jar files in the current directory, and you’re using JDK 6 or later, you can use a single-asterisk. In a unix shell (like in Linux), you’ll need to escape the asterisk:

    javac -cp \* Canvas.java
    

    This works when running the Java application as well:

    java -cp .:\* Canvas
    

    Note the .: to tell Java to look in the current directory as well as the *.jar files to find Canvas.class.

    On Windows, use a semicolon (;) instead of a colon as a separator.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Working on my first rails project so please pardon any incorrect terminology. I created
Pardon me if it is nave; but i am trying to set a property
Pardon the simple question, but I am pulling my hair out trying to get
I am new to Android and Java so pardon me if the question sounds
Pardon my naivety, its my first time here and first time dealing with animation
Pardon the total newbiew question but why is @game_score always nil? #bowling.rb class Bowling
Please pardon my lack of 100% specific technical language… I'm a bit of a
Please pardon me for a n00bish question. Please consider the following code: public class
this will be the first question I've posted here so pardon any unintended lapses
Pardon any mistaken terminology; I am relatively new to Scala. I will endeavor to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.