Event-driven programming

Discussion in 'Java' started by sebek, May 27, 2007.

  1. sebek

    sebek Guest

    Hi,
    I have a look for framework like Prado (event-driven programming) for
    Java. Do you know something?

    Thanx!
    sebek, May 27, 2007
    #1
    1. Advertising

  2. sebek

    Daniel Pitts Guest

    On May 27, 3:37 pm, sebek <> wrote:
    > Hi,
    > I have a look for framework like Prado (event-driven programming) for
    > Java. Do you know something?
    >
    > Thanx!


    I know lots of things. Many of them about Java, some of them about
    event-driven programming, and none of them about Prado.

    Did you have any other questions? Preferable more specific.
    Daniel Pitts, May 28, 2007
    #2
    1. Advertising

  3. sebek

    sebek Guest

    On 28 Maj, 06:22, Daniel Pitts <> wrote:
    > Did you have any other questions? Preferable more specific.


    I`m searching something like Prado in Java. My question, is framework
    that allow event-driven programming?
    sebek, May 28, 2007
    #3
  4. sebek

    Oliver Wong Guest

    "sebek" <> wrote in message
    news:...
    > On 28 Maj, 06:22, Daniel Pitts <> wrote:
    >
    > I`m searching something like Prado in Java. My question, is framework
    > that allow event-driven programming?
    >


    Swing is pretty event-driven, I think.

    Do you plan on using this framework for application development or web
    development? I ask, because Prado is a web framework.

    - Oliver
    Oliver Wong, May 28, 2007
    #4
  5. sebek

    sebek Guest

    On 28 Maj, 20:34, "Oliver Wong" <> wrote:
    > Do you plan on using this framework for application development or web
    > development? I ask, because Prado is a web framework.


    Web development. Is it good choice (event-driven programming)?
    sebek, May 28, 2007
    #5
  6. sebek

    Lew Guest

    "Oliver Wong" wrote:
    >> Do you plan on using this framework for application development or web
    >> development? I ask, because Prado is a web framework.


    sebek wrote:
    > Web development. Is it good choice (event-driven programming)?


    IMHO event-driven programming is a useful technique, but the term does not
    encompass all there is to programming.

    Like many other techniques, it has a place and it is a good orientation for an
    application framework, but it is not the final answer to all programming
    questions.

    Think of the furniture maker. Is a hammer a good tool? Is a saw? That
    depends in part on whether you are putting things together or taking them apart.

    Another framework that supports an event-driven approach for web apps is Java
    Server Faces (JSF) from Sun.

    All good frameworks require study.

    I am slowly learning JSF myself.

    --
    Lew
    Lew, May 29, 2007
    #6
  7. sebek

    Oliver Wong Guest

    "sebek" <> wrote in message
    news:...
    > On 28 Maj, 20:34, "Oliver Wong" <> wrote:
    >> Do you plan on using this framework for application development or
    >> web
    >> development? I ask, because Prado is a web framework.

    >
    > Web development. Is it good choice (event-driven programming)?
    >


    I don't even know what "event-driven" means, in the context of a web
    application.

    Are the events the HTTP requests? If so, then how is "event-driven web
    app" different from "normal web app"? If not, then what are the events?

    - Oliver
    Oliver Wong, May 29, 2007
    #7
  8. sebek

    Tom Hawtin Guest

    Oliver Wong wrote:
    >
    > I don't even know what "event-driven" means, in the context of a web
    > application.
    >
    > Are the events the HTTP requests? If so, then how is "event-driven web
    > app" different from "normal web app"? If not, then what are the events?


    A POST (or I guess PUT, DELETE, etc) would be an input event. Generally,
    then have some standard code that updates some state associated with the
    form (persisted in some random way). That change of state would then
    fire state change events.

    Tom Hawtin
    Tom Hawtin, May 29, 2007
    #8
  9. sebek

    Daniel Pitts Guest

    On May 29, 6:28 am, "Oliver Wong" <> wrote:
    > "sebek" <> wrote in message
    >
    > news:...
    >
    > > On 28 Maj, 20:34, "Oliver Wong" <> wrote:
    > >> Do you plan on using this framework for application development or
    > >> web
    > >> development? I ask, because Prado is a web framework.

    >
    > > Web development. Is it good choice (event-driven programming)?

    >
    > I don't even know what "event-driven" means, in the context of a web
    > application.
    >
    > Are the events the HTTP requests? If so, then how is "event-driven web
    > app" different from "normal web app"? If not, then what are the events?
    >
    > - Oliver


    Often, a event-driven webapp might use Ajax, or Cometd to push/poll
    events between the server/client. Also, Spring Web Flow is considered
    event-oriented. The actual HTTP request isn't the event, but instead
    describes the event (the user clicked on button A, or the user clicked
    on button B).

    Event-driven is often just a way to explain the information flow
    within an application. If you get down to it, all programs are finite-
    state Turing machines.
    Daniel Pitts, May 29, 2007
    #9
  10. sebek

    Oliver Wong Guest

    "Daniel Pitts" <> wrote in message
    news:...
    > On May 29, 6:28 am, "Oliver Wong" <> wrote:
    >>
    >> I don't even know what "event-driven" means, in the context of a
    >> web
    >> application.
    >>
    >> Are the events the HTTP requests? If so, then how is "event-driven
    >> web
    >> app" different from "normal web app"? If not, then what are the events?
    >>

    >
    > Often, a event-driven webapp might use Ajax, or Cometd to push/poll
    > events between the server/client. Also, Spring Web Flow is considered
    > event-oriented. The actual HTTP request isn't the event, but instead
    > describes the event (the user clicked on button A, or the user clicked
    > on button B).
    >
    > Event-driven is often just a way to explain the information flow
    > within an application. If you get down to it, all programs are finite-
    > state Turing machines.


    To me, the main difference between event-driven applications and
    non-event-driven applications are that with event-driven applications,
    when someone asks you to point at the line of code that's currently
    executing, it's possible for you to say that there isn't any such line,
    that the system is waiting for an event to occur to trigger some
    behaviour. E.g. contrast these two pseudocode listings:

    Begin Program
    Print "What is your name?"
    Input $NAME
    Print "Hello " + $NAME
    End Program

    Begin Program
    On Key Down $KEY_ID
    Begin Subprocedure
    Print "You pressed key: " + $KEY_ID
    End Subprocedure
    On Key Up $KEY_ID
    Begin Subprocedure
    Print "You released key: " + $KEY_ID
    End Subprocedure
    End Program

    With the first program, even if the program is idly waiting for input,
    you can point to the "Input $NAME" line and say "This is the line that's
    currently executing", whereas you can't really do the same with the second
    program.

    Almost every web app I've seen is, in this sense, event-driven. Code
    usually runs in response to a visitor requesting some web page. When
    there's no visitors, there's no requests, and thus none of your code is
    running (the server's code may be running, but I consider the server to be
    a distinct application form your web app).

    - Oliver
    Oliver Wong, May 29, 2007
    #10
  11. Tom Hawtin wrote:
    > Oliver Wong wrote:
    >>
    >> I don't even know what "event-driven" means, in the context of a
    >> web application.
    >>
    >> Are the events the HTTP requests? If so, then how is "event-driven
    >> web app" different from "normal web app"? If not, then what are the
    >> events?

    >
    > A POST (or I guess PUT, DELETE, etc) would be an input event. Generally,
    > then have some standard code that updates some state associated with the
    > form (persisted in some random way). That change of state would then
    > fire state change events.


    That sounds a lot like JSF with a JSP and a backing bean.

    Arne
    =?ISO-8859-1?Q?Arne_Vajh=F8j?=, Jun 3, 2007
    #11
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. christopher diggins
    Replies:
    4
    Views:
    400
    christopher diggins
    Dec 21, 2004
  2. Steve
    Replies:
    2
    Views:
    551
    Carl Cerecke
    Jan 23, 2006
  3. Kottiyath

    Event Driven programming - Doubts

    Kottiyath, Dec 22, 2008, in forum: Python
    Replies:
    3
    Views:
    382
    Bryan Olson
    Dec 23, 2008
  4. Bruce Cook

    Re: event driven programming

    Bruce Cook, Dec 25, 2009, in forum: C Programming
    Replies:
    0
    Views:
    418
    Bruce Cook
    Dec 25, 2009
  5. Herbert Rosenau

    Re: event driven programming

    Herbert Rosenau, Dec 27, 2009, in forum: C Programming
    Replies:
    1
    Views:
    508
    Nobody
    Dec 29, 2009
Loading...

Share This Page