Knowledge

Event (computing)

Source đź“ť

242: 814: 895:
systems (used to inform applications when conditions they are watching for have occurred), modern operating systems (used to inform applications when they should take some action, such as refreshing a window), and modern distributed systems, where the producer of an event might be on a different
133:
Events are typically used in user interfaces, where actions in the outside world (such as mouse clicks, window-resizing, keyboard presses, and messages from other programs) are handled by the program as a series of events. Programs written for many windowing environments consist predominantly of
799:
within the framework. It typically manages the associations between events and event handlers, and may queue event handlers or events for later processing. Event dispatchers may call event handlers directly, or wait for events to be dequeued with information about the handler to be executed.
775:
The events are created by the framework based on interpreting lower-level inputs, which may be lower-level events themselves. For example, mouse movements and clicks are interpreted as menu selections. The events initially originate from actions on the operating system level, such as
145:. Compared to interrupts, events are normally implemented synchronously: the program explicitly waits for an event to be generated and handled (typically by calling an instruction that dispatches the next event), whereas an interrupt can demand immediate service. 896:
machine than the consumer, or consumers. Event notification platforms are normally designed so that the application producing events do not need to know which applications will consume them, or even how many applications will monitor the event stream.
125:
for a particular event. The data associated with an event at a minimum specifies what type of event it is, but may include other information such as when it occurred, who or what caused it to occur, and extra data provided by the event
109:
Event driven systems are typically used when there is some asynchronous external activity that needs to be handled by a program, such as a user pressing a mouse button. An event driven system typically runs an
189:
Pressing a key on a keyboard or a combination of keys generates a keyboard event, enabling the program currently running to respond to the introduced data such as which key/s the user pressed.
93:. Software can also trigger its own set of events into the event loop, such as by communicating the completion of a task. Software that changes its behavior in response to events is said to be 114:
that keeps waiting for such activities, such as input from devices or internal alarms. When one of these occurs, it collects data about the event and dispatches the event to the
1070: 1110: 768:
expiring. On a lower level, events can represent availability of new data for reading a file or network stream. Event handlers are a central concept in
907:
model is sometimes used to endow event notification systems, and publish-subscribe systems, with stronger fault-tolerance and consistency guarantees.
169:. A mouse can generate a number of mouse events, such as mouse move (including direction of move and distance), mouse left/right button up/down and 153:
There are many situations or events that a program or system may generate or to which it may respond. Some common user generated events include:
286: 1100: 1092: 835: 121:
A program can choose to ignore events, and there may be libraries to dispatch an event to multiple handlers that may be programmed to
861: 307:
every time the source generates the event, it communicates it to the registered listeners, following the protocol of the interface.
1060: 916: 74: 839: 315: 311: 1081: 1125: 282: 1130: 741: 730: 254: 781: 1031: 888:(the "events") to applications that monitor the associated conditions and may take actions triggered by events. 314:
uses events as special delegates that can only be fired by the class that declares them. This allows for better
931: 824: 769: 724: 298: 258: 94: 843: 828: 166: 262: 903:, a term that relates to one class of products supporting event notification in networked settings. The 749: 1065: 66:. That is, the software may have one or more dedicated places where events are handled, frequently an 1135: 82: 31: 1013:. Institut fĂĽr Systemsoftware, Johannes Kepler Universität Linz, Fachbereich Informatik. p. 26 222: 966: 936: 1007: 993: 249:
is the event source –a button in this example–, and it contains a list of listeners.
971: 941: 904: 900: 878: 785: 757: 86: 961: 951: 921: 272: 241: 55: 47: 201:
generates an X-Y analogue signal. They often have multiple buttons to trigger events. Some
957: 233:
Device events include action by or to a device, such as a shake, tilt, rotation, or move.
162: 138: 59: 35: 304:
every listener must register with the source to declare its desire to listen to the event
789: 761: 1119: 276: 98: 54:
by the software. Computer events can be generated or triggered by the system, by the
51: 780:
generated by hardware devices, software interrupt instructions, or state changes in
1104: 178: 174: 170: 63: 17: 1075: 1054: 813: 753: 218: 214: 926: 777: 748:). Each event is a piece of application-level information from the underlying 745: 733: 111: 78: 67: 946: 142: 892: 885: 881: 198: 43: 1085: 202: 729:
In computer programming, an event handler may be implemented using a
765: 240: 90: 807: 177:
commonly select words and characters within boundary, and
173:
motion, or a combination of these gestures. For example,
285:(in the broader meaning of the term) which describe the 130:
to the handler about how the event should be processed.
1032:"EventTarget.addEventListener() - Web APIs | MDN" 899:
Event notification is sometimes used as a synonym for
279:, which receive the event notification from the source 891:
Event notification is an important feature in modern
73:
The user can be the source of an event. The user may
736:
that handles inputs received in a program (called a
297:
every listener must implement the interface for the
58:, or in other ways. Typically, events are handled 1061:A High Level Design of the Sub-Farm Event Handler 503:$ "{sender} was changed during update" 165:can generate a number of software recognisable 725:Event-driven programming § Event handlers 85:or clicking with a mouse. Another source is a 884:for linking applications that generate small 8: 1008:"Advanced C#: Variable Number of Parameters" 996:. Microsoft. Retrieved on February 12, 2008. 842:. Unsourced material may be challenged and 50:from the external environment, that may be 27:Action or occurrence recognized by software 994:Mouse and Keyboard Events in Windows Forms 862:Learn how and when to remove this message 795:Created events are first processed by an 289:by which the event is to be communicated. 265:. This model is based on three entities: 77:with the software through the computer's 42:is an action or occurrence recognized by 989: 987: 983: 205:for popular game boxes use joysticks. 1096:Java package Javadoc API documentation 293:Furthermore, the model requires that: 1055:Event Handlers and Callback Functions 7: 1071:Distributed Events and Notifications 1006:Mössenböck, Hanspeter (2002-03-25). 840:adding citations to reliable sources 269:a control, which is the event source 877:is a term used in conjunction with 614:$ "{sender} was changed" 25: 764:movement, action selections, and 118:software that will deal with it. 812: 917:Callback (computer programming) 137:Events can also be used at the 97:, often with the goal of being 792:correspond to event handlers. 81:- for example, by typing on a 1: 213:The events generated using a 141:level, where they complement 261:, which is provided by some 217:are commonly referred to as 301:to which it wants to listen 255:object-oriented programming 1152: 722: 181:select entire paragraphs. 1107:Javadoc API documentation 1082:Java DOM Interface Event 1066:An Events Syntax for XML 932:Event-driven programming 770:event-driven programming 320: 167:pointing device gestures 263:graphic user interfaces 1111:Write an Event Handler 954:(e.g., Event listener) 250: 245:Delegate event model. 1036:developer.mozilla.org 756:. GUI events include 723:Further information: 244: 149:User-generated events 1126:Computer programming 836:improve this section 259:delegate event model 253:A common variant in 237:Delegate event model 46:, often originating 1131:Events (computing) 967:Signal programming 937:Exception handling 875:Event notification 804:Event notification 786:interrupt handlers 251: 209:Touchscreen events 18:Event notification 1101:javax.swing.event 972:Virtual synchrony 942:Interrupt handler 905:virtual synchrony 901:publish-subscribe 872: 871: 864: 784:. On this level, 392:"Model" 89:device such as a 16:(Redirected from 1143: 1103: 1095: 1084: 1040: 1039: 1038:. 11 March 2024. 1028: 1022: 1021: 1019: 1018: 1012: 1003: 997: 991: 962:Proactor pattern 952:Observer pattern 922:Database trigger 867: 860: 856: 853: 847: 816: 808: 797:event dispatcher 752:, typically the 714: 711: 708: 705: 702: 699: 696: 693: 690: 687: 684: 681: 678: 675: 672: 669: 666: 663: 660: 657: 654: 651: 648: 645: 642: 639: 636: 633: 630: 627: 624: 621: 618: 615: 612: 609: 606: 603: 600: 597: 594: 591: 588: 585: 582: 579: 576: 573: 570: 567: 564: 561: 558: 555: 552: 549: 546: 543: 540: 537: 534: 531: 528: 525: 522: 519: 516: 513: 510: 507: 504: 501: 498: 495: 492: 489: 486: 483: 480: 477: 474: 471: 468: 465: 462: 459: 456: 453: 450: 447: 444: 441: 438: 435: 432: 429: 426: 423: 420: 417: 414: 411: 408: 405: 402: 399: 396: 393: 390: 387: 384: 381: 378: 375: 372: 369: 366: 363: 360: 357: 354: 351: 348: 345: 342: 339: 336: 333: 330: 327: 324: 248: 134:event handlers. 21: 1151: 1150: 1146: 1145: 1144: 1142: 1141: 1140: 1116: 1115: 1099: 1091: 1080: 1049: 1044: 1043: 1030: 1029: 1025: 1016: 1014: 1010: 1005: 1004: 1000: 992: 985: 980: 958:Reactor pattern 913: 868: 857: 851: 848: 833: 817: 806: 790:signal handlers 727: 721: 716: 715: 712: 709: 706: 703: 700: 697: 694: 691: 688: 685: 682: 679: 676: 673: 670: 667: 664: 661: 658: 655: 652: 649: 646: 643: 640: 637: 634: 631: 628: 625: 622: 619: 616: 613: 610: 607: 604: 601: 598: 595: 592: 589: 586: 583: 580: 577: 574: 571: 568: 565: 562: 559: 556: 553: 550: 547: 544: 541: 538: 535: 532: 529: 526: 523: 520: 517: 514: 511: 508: 505: 502: 499: 496: 493: 490: 487: 484: 481: 478: 475: 472: 469: 466: 463: 460: 457: 454: 451: 448: 445: 442: 439: 436: 433: 430: 427: 424: 421: 418: 415: 412: 409: 406: 403: 400: 397: 394: 391: 388: 385: 382: 379: 376: 373: 370: 367: 364: 361: 358: 355: 352: 349: 346: 343: 340: 337: 334: 331: 328: 325: 322: 318:, for example: 246: 239: 231: 211: 195: 193:Joystick events 187: 185:Keyboard events 163:pointing device 159: 151: 139:instruction set 107: 36:software design 28: 23: 22: 15: 12: 11: 5: 1149: 1147: 1139: 1138: 1133: 1128: 1118: 1117: 1114: 1113: 1108: 1097: 1093:java.awt.event 1089: 1078: 1073: 1068: 1063: 1058: 1048: 1047:External links 1045: 1042: 1041: 1023: 998: 982: 981: 979: 976: 975: 974: 969: 964: 955: 949: 944: 939: 934: 929: 924: 919: 912: 909: 879:communications 870: 869: 820: 818: 811: 805: 802: 720: 717: 321: 309: 308: 305: 302: 291: 290: 280: 277:event handlers 275:, also called 270: 238: 235: 230: 227: 210: 207: 194: 191: 186: 183: 158: 155: 150: 147: 106: 103: 48:asynchronously 26: 24: 14: 13: 10: 9: 6: 4: 3: 2: 1148: 1137: 1134: 1132: 1129: 1127: 1124: 1123: 1121: 1112: 1109: 1106: 1102: 1098: 1094: 1090: 1088:documentation 1087: 1083: 1079: 1077: 1074: 1072: 1069: 1067: 1064: 1062: 1059: 1057: 1056: 1051: 1050: 1046: 1037: 1033: 1027: 1024: 1009: 1002: 999: 995: 990: 988: 984: 977: 973: 970: 968: 965: 963: 959: 956: 953: 950: 948: 945: 943: 940: 938: 935: 933: 930: 928: 925: 923: 920: 918: 915: 914: 910: 908: 906: 902: 897: 894: 889: 887: 883: 880: 876: 866: 863: 855: 845: 841: 837: 831: 830: 826: 821:This section 819: 815: 810: 809: 803: 801: 798: 793: 791: 787: 783: 779: 773: 771: 767: 763: 759: 755: 751: 747: 743: 739: 735: 732: 726: 719:Event handler 718: 319: 317: 313: 306: 303: 300: 296: 295: 294: 288: 284: 281: 278: 274: 271: 268: 267: 266: 264: 260: 256: 243: 236: 234: 229:Device events 228: 226: 224: 220: 216: 208: 206: 204: 200: 192: 190: 184: 182: 180: 179:triple-clicks 176: 175:double-clicks 172: 168: 164: 156: 154: 148: 146: 144: 140: 135: 131: 129: 124: 119: 117: 116:event handler 113: 104: 102: 100: 96: 92: 88: 84: 80: 76: 71: 69: 65: 61: 60:synchronously 57: 53: 49: 45: 41: 37: 33: 19: 1105:Java package 1053: 1035: 1026: 1015:. Retrieved 1001: 898: 890: 874: 873: 858: 849: 834:Please help 822: 796: 794: 774: 737: 728: 310: 292: 252: 232: 219:touch events 212: 196: 188: 160: 157:Mouse events 152: 136: 132: 127: 122: 120: 115: 108: 95:event-driven 72: 64:program flow 39: 29: 1136:Subroutines 1076:Event order 754:GUI toolkit 551:notifyViews 440:notifyViews 386:notifyViews 362:notifyViews 316:abstraction 215:touchscreen 171:mouse wheel 105:Description 99:interactive 79:peripherals 32:programming 1120:Categories 1017:2011-08-05 978:References 947:Interrupts 927:DOM events 778:interrupts 746:JavaScript 734:subroutine 283:interfaces 143:interrupts 112:event loop 68:event loop 852:June 2007 823:does not 760:presses, 750:framework 608:WriteLine 497:WriteLine 273:listeners 197:Moving a 62:with the 1052:Article 911:See also 893:database 886:messages 882:software 738:listener 731:callback 560:Notifier 449:Notifier 359:Notifier 329:Notifier 323:delegate 287:protocol 223:gestures 203:gamepads 199:joystick 87:hardware 83:keyboard 75:interact 44:software 1086:Javadoc 844:removed 829:sources 782:polling 602:Console 584:Update2 572:Update2 491:Console 473:Update1 461:Update1 257:is the 247:clickme 52:handled 766:timers 704:Change 635:static 593:sender 590:string 524:public 482:sender 479:string 413:public 374:Change 368:public 353:public 338:sender 335:string 128:source 123:listen 1011:(PDF) 762:mouse 698:model 692:model 686:View2 677:model 671:View1 662:Model 653:model 650:Model 626:class 545:model 536:model 533:Model 527:View2 518:View2 515:class 434:model 425:model 422:Model 416:View1 407:View1 404:class 356:event 347:Model 344:class 299:event 91:timer 40:event 38:, an 960:vs. 827:any 825:cite 788:and 744:and 742:Java 641:Main 638:void 629:Test 581:void 566:this 470:void 455:this 371:void 326:void 56:user 34:and 838:by 758:key 740:in 707:(); 683:new 668:new 665:(); 659:new 557:new 446:new 383:... 221:or 70:. 30:In 1122:: 1034:. 986:^ 772:. 695:); 680:); 644:() 617:); 575:); 554:+= 506:); 464:); 443:+= 395:); 377:() 341:); 312:C# 225:. 161:A 101:. 1020:. 865:) 859:( 854:) 850:( 846:. 832:. 713:} 710:} 701:. 689:( 674:( 656:= 647:{ 632:{ 623:} 620:} 611:( 605:. 599:{ 596:) 587:( 578:} 569:. 563:( 548:. 542:{ 539:) 530:( 521:{ 512:} 509:} 500:( 494:. 488:{ 485:) 476:( 467:} 458:. 452:( 437:. 431:{ 428:) 419:( 410:{ 401:} 398:} 389:( 380:{ 365:; 350:{ 332:( 20:)

Index

Event notification
programming
software design
software
asynchronously
handled
user
synchronously
program flow
event loop
interact
peripherals
keyboard
hardware
timer
event-driven
interactive
event loop
instruction set
interrupts
pointing device
pointing device gestures
mouse wheel
double-clicks
triple-clicks
joystick
gamepads
touchscreen
touch events
gestures

Text is available under the Creative Commons Attribution-ShareAlike License. Additional terms may apply.

↑