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

  • Home
  • SEARCH
  • 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 4250548
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T04:32:34+00:00 2026-05-21T04:32:34+00:00

I develop a lot of small apps where I work. As a result, I’ve

  • 0

I develop a lot of small apps where I work. As a result, I’ve switched from using gridbag in most places to using the netbeans form builder. I sometimes use grid layout, box layout and flow layout.

I’ve found that instead of developing a seperate controller object that I often simply double click on the button that I want to add functionality to and then I add the call to the database adapter interface from there.

Is this wrong?

Situation:

I have a Cat class and a Cat herder class and they both exist in the database. I have a view that gets the most recent cat from the database and tells me which cat herder it belongs to.

Should this button talk to an intermediary controller or is the ActionListener that fire the ActionPerformed the controller?

  • 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-21T04:32:35+00:00Added an answer on May 21, 2026 at 4:32 am

    I would say that depends on how much business logic your application is doing.

    I have written an app exactly the way you describe. I laid out all the panels in Netbeans, and wrote SQL statements to fetch the data directly into my frame/panel classes. I double-clicked the buttons I created and any actions that needed to occur, I also wrote the code into the generated methods in my frame/panel classes.

    However: This application was simply to read/write stuff from a database, display the data on the screen and allow it to be edited. There was absolutely no logic in the code, there was hardly even any validation.

    If there is any kind of logic or processes which need to happen (which most apps have) then I would create objects to perform those actions, which themselves e.g. execute SQL statements or whatever. Firstly that makes the code easier to write (separation of logic and presentation) and secondly easier to re-use (e.g. two buttons on different forms which perform the same action). However, it is a more complex application design, and complexity should only be introduced if it is justified.

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

Sidebar

Related Questions

I develop and maintain small intranet web apps written in JSP and Java. They
I am starting to redesign and develop a site that contains a lot of
Okay, I develop web applications in PHP and JavaScript and a lot of times
My company develops several types of applications. A lot of our business comes from
I develop a number of desktop Java applications using Swing, and while Swing is
I'm learning to develop apps for Iphone. I follow a book by Apress which
I need to develop an app that is using multithreading. Basicly, I have a
I develop exclusively on VMs. I currently run Boot Camp on a MacBook Pro
I develop an extension module for Guile, written in C. This extension module embeds
We develop custom survey web sites and I am looking for a way 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.