Signal.st
branchjv
changeset 17797 71451ae83564
parent 17780 b6e42c92eba0
child 17807 06cc6c49e291
equal deleted inserted replaced
17796:2fe4a1c91aa9 17797:71451ae83564
   508     "raise a signal nonproceedable.
   508     "raise a signal nonproceedable.
   509      The signals notifierString is used as messageText."
   509      The signals notifierString is used as messageText."
   510 
   510 
   511     <context: #return>
   511     <context: #return>
   512 
   512 
   513     ^ (self newException
   513     ^ self newException
   514         suspendedContext:thisContext sender)
   514         raiseIn:thisContext sender
   515         raise
   515 
   516 
   516     "Created: / 23-07-1999 / 14:07:17 / stefan"
   517     "Modified: / 2.5.1996 / 16:36:23 / cg"
   517     "Modified: / 10-08-2010 / 09:58:57 / cg"
   518     "Modified: / 5.3.1998 / 16:44:36 / stefan"
       
   519     "Created: / 23.7.1999 / 14:07:17 / stefan"
       
   520 !
   518 !
   521 
   519 
   522 raiseErrorString:aString
   520 raiseErrorString:aString
   523     "raise a signal nonproceedable.
   521     "raise a signal nonproceedable.
   524      The argument is used as messageText."
   522      The argument is used as messageText."
   525 
   523 
   526     <context: #return>
   524     <context: #return>
   527 
   525 
   528     ^ (self newException
   526     ^ self newException
   529         suspendedContext:(thisContext sender) errorString:aString)
   527         raiseErrorString:aString in:thisContext sender
   530             raise.
   528 
   531 
   529     "Created: / 23-07-1999 / 14:07:33 / stefan"
   532     "Modified: / 9.5.1996 / 15:17:59 / cg"
   530     "Modified: / 10-08-2010 / 09:59:22 / cg"
   533     "Modified: / 12.3.1998 / 15:15:22 / stefan"
       
   534     "Created: / 23.7.1999 / 14:07:33 / stefan"
       
   535 !
   531 !
   536 
   532 
   537 raiseErrorString:aString in:aContext
   533 raiseErrorString:aString in:aContext
   538     "raise a signal nonproceedable.
   534     "raise a signal nonproceedable.
   539      The argument is used as messageText."
   535      The argument is used as messageText."
   540 
   536 
   541     <context: #return>
   537     <context: #return>
   542 
   538 
   543     ^ (self newException
   539     ^ self newException
   544         suspendedContext:aContext errorString:aString)
   540         raiseErrorString:aString in:aContext
   545             raise.
   541 
   546 
   542     "Created: / 23-07-1999 / 14:07:33 / stefan"
   547     "Modified: / 9.5.1996 / 15:17:59 / cg"
   543     "Modified: / 10-08-2010 / 09:59:58 / cg"
   548     "Modified: / 12.3.1998 / 15:15:22 / stefan"
       
   549     "Created: / 23.7.1999 / 14:07:33 / stefan"
       
   550 !
   544 !
   551 
   545 
   552 raiseFrom:something 
   546 raiseFrom:something 
   553     "raise a signal nonproceedable.
   547     "raise a signal nonproceedable.
   554      The argument, something is passed both as parameter and originator."
   548      The argument, something is passed both as parameter and originator."
   555     
   549     
   556     <context: #return>
   550     <context: #return>
   557 
   551 
   558     ^ (self newException
   552     ^ (self newException
   559         suspendedContext:(thisContext sender) parameter:something originator:something)
   553             suspendedContext:(thisContext sender) parameter:something originator:something)
   560         raise
   554         raise
   561 
   555 
   562     "Modified: / 2.5.1996 / 16:36:38 / cg"
   556     "Created: / 23-07-1999 / 14:07:59 / stefan"
   563     "Modified: / 5.3.1998 / 16:49:55 / stefan"
   557     "Modified: / 10-08-2010 / 09:58:36 / cg"
   564     "Created: / 23.7.1999 / 14:07:59 / stefan"
       
   565 !
   558 !
   566 
   559 
   567 raiseRequest
   560 raiseRequest
   568     "raise a signal proceedable.
   561     "raise a signal proceedable.
   569      The signals notifierString is used as messageText."
   562      The signals notifierString is used as messageText."
   570 
   563 
   571     <context: #return>
   564     <context: #return>
   572 
   565 
   573     ^ (self newException
   566     ^ self newException
   574         suspendedContext:thisContext sender)
   567         raiseRequestIn:thisContext sender
   575         raiseRequest.
   568 
   576 
   569     "Created: / 23-07-1999 / 14:08:24 / stefan"
   577     "Modified: / 2.5.1996 / 16:36:52 / cg"
   570     "Modified: / 10-08-2010 / 10:00:13 / cg"
   578     "Modified: / 5.3.1998 / 16:50:46 / stefan"
       
   579     "Created: / 23.7.1999 / 14:08:24 / stefan"
       
   580 !
   571 !
   581 
   572 
   582 raiseRequestErrorString:aString
   573 raiseRequestErrorString:aString
   583     "raise a signal proceedable.
   574     "raise a signal proceedable.
   584      The argument, aString is used as messageText."
   575      The argument, aString is used as messageText."
   585 
   576 
   586     <context: #return>
   577     <context: #return>
   587 
   578 
   588     ^ (self newException
   579     ^ self newException
   589         suspendedContext:(thisContext sender) errorString:aString)
   580         raiseRequestErrorString:aString in:thisContext sender
   590         raiseRequest
   581 
       
   582     "Modified: / 10-08-2010 / 10:00:40 / cg"
   591 !
   583 !
   592 
   584 
   593 raiseRequestFrom:something 
   585 raiseRequestFrom:something 
   594     "raise a signal proceedable.
   586     "raise a signal proceedable.
   595      The argument, something is passed both as parameter and originator."
   587      The argument, something is passed both as parameter and originator."
   609     "raise a signal proceedable.
   601     "raise a signal proceedable.
   610      The signals notifierString is used as messageText."
   602      The signals notifierString is used as messageText."
   611 
   603 
   612     <context: #return>
   604     <context: #return>
   613 
   605 
   614     ^ (self newException
   606     ^ self newException
   615         suspendedContext:(thisContext sender) parameter:aParameter)
   607         raiseRequestWith:aParameter in:thisContext sender
   616         raiseRequest.
   608 
   617 
   609     "Created: / 23-07-1999 / 14:08:48 / stefan"
   618     "Modified: / 9.5.1996 / 15:13:20 / cg"
   610     "Modified: / 10-08-2010 / 10:01:00 / cg"
   619     "Modified: / 12.3.1998 / 15:16:57 / stefan"
       
   620     "Created: / 23.7.1999 / 14:08:48 / stefan"
       
   621 !
   611 !
   622 
   612 
   623 raiseRequestWith:aParameter errorString:aString
   613 raiseRequestWith:aParameter errorString:aString
   624     "raise a signal proceedable.
   614     "raise a signal proceedable.
   625      The argument, aString is used as messageText."
   615      The argument, aString is used as messageText."
   626 
   616 
   627     <context: #return>
   617     <context: #return>
   628 
   618 
   629     ^ (self newException
   619     ^ self newException
   630         suspendedContext:(thisContext sender) parameter:aParameter errorString:aString)
   620         raiseRequestWith:aParameter errorString:aString in:thisContext sender
   631         raiseRequest
   621 
   632 
   622     "Created: / 23-07-1999 / 14:08:57 / stefan"
   633     "Modified: / 9.5.1996 / 15:13:35 / cg"
   623     "Modified: / 10-08-2010 / 10:01:38 / cg"
   634     "Modified: / 12.3.1998 / 15:17:52 / stefan"
       
   635     "Created: / 23.7.1999 / 14:08:57 / stefan"
       
   636 !
   624 !
   637 
   625 
   638 raiseRequestWith:aParameter errorString:aString in:aContext
   626 raiseRequestWith:aParameter errorString:aString in:aContext
   639     "raise a signal proceedable.
   627     "raise a signal proceedable.
   640      The argument, aString is used as messageText.
   628      The argument, aString is used as messageText.
   641      The additional context is passed as the context responsible for the raise,
   629      The additional context is passed as the context responsible for the raise,
   642      allowing a raise to mimicri the exception happened somewhere else."
   630      allowing a raise to mimicri the exception happened somewhere else."
   643 
   631 
   644     <context: #return>
   632     <context: #return>
   645 
   633 
   646     ^ (self newException
   634     ^ self newException
   647         suspendedContext:aContext parameter:aParameter errorString:aString)
   635         raiseRequestWith:aParameter errorString:aString in:aContext
   648         raiseRequest
   636 
   649 
   637     "Created: / 23-07-1999 / 14:09:07 / stefan"
   650     "Modified: / 26.7.1996 / 16:29:27 / cg"
   638     "Modified: / 10-08-2010 / 10:02:08 / cg"
   651     "Modified: / 12.3.1998 / 15:18:34 / stefan"
       
   652     "Created: / 23.7.1999 / 14:09:07 / stefan"
       
   653 !
   639 !
   654 
   640 
   655 raiseRequestWith:aParameter in:aContext
   641 raiseRequestWith:aParameter in:aContext
   656     "raise a signal proceedable.
   642     "raise a signal proceedable.
   657      The additional context is passed as the context responsible for the raise,
   643      The additional context is passed as the context responsible for the raise,
   658      allowing a raise to mimicri the exception happened somewhere else."
   644      allowing a raise to mimicri the exception happened somewhere else."
   659 
   645 
   660     <context: #return>
   646     <context: #return>
   661 
   647 
   662     ^ (self newException
   648     ^ self newException
   663         suspendedContext:aContext parameter:aParameter)
   649         raiseRequestWith:aParameter in:aContext
   664         raiseRequest
   650 
       
   651     "Modified: / 10-08-2010 / 10:02:26 / cg"
   665 !
   652 !
   666 
   653 
   667 raiseSignal
   654 raiseSignal
   668     "raise a signal (proceedable or not, whatever the proceedability is).
   655     "raise a signal (proceedable or not, whatever the proceedability is).
   669      The signals notifierString is used as messageText."
   656      The signals notifierString is used as messageText."
   741     "raise a signal nonproceedable.
   728     "raise a signal nonproceedable.
   742      The argument, aParameter is passed as parameter."
   729      The argument, aParameter is passed as parameter."
   743 
   730 
   744     <context: #return>
   731     <context: #return>
   745 
   732 
   746     ^ (self newException
   733     ^ self newException
   747         suspendedContext:(thisContext sender) parameter:aParameter)
   734         raiseWith:aParameter in:thisContext sender
   748         raise.
   735 
   749 
   736     "Created: / 23-07-1999 / 14:09:27 / stefan"
   750     "Modified: / 9.5.1996 / 15:14:24 / cg"
   737     "Modified: / 10-08-2010 / 10:02:51 / cg"
   751     "Modified: / 12.3.1998 / 15:19:11 / stefan"
       
   752     "Created: / 23.7.1999 / 14:09:27 / stefan"
       
   753 !
   738 !
   754 
   739 
   755 raiseWith:aParameter errorString:aString
   740 raiseWith:aParameter errorString:aString
   756     "raise a signal nonproceedable.
   741     "raise a signal nonproceedable.
   757      The argument, aString is used as messageText,
   742      The argument, aString is used as messageText,
   758      aParameter is passed as exception parameter."
   743      aParameter is passed as exception parameter."
   759 
   744 
   760     <context: #return>
   745     <context: #return>
   761 
   746 
   762     ^ (self newException
   747     ^ self newException
   763         suspendedContext:(thisContext sender) parameter:aParameter errorString:aString)
   748         raiseWith:aParameter errorString:aString in:thisContext sender
   764         raise.
   749 
   765 
   750     "Created: / 23-07-1999 / 14:09:36 / stefan"
   766     "Modified: / 9.5.1996 / 15:14:32 / cg"
   751     "Modified: / 10-08-2010 / 10:03:29 / cg"
   767     "Modified: / 12.3.1998 / 15:19:40 / stefan"
       
   768     "Created: / 23.7.1999 / 14:09:36 / stefan"
       
   769 !
   752 !
   770 
   753 
   771 raiseWith:aParameter errorString:aString in:aContext
   754 raiseWith:aParameter errorString:aString in:aContext
   772     "raise a signal nonproceedable.
   755     "raise a signal nonproceedable.
   773      The argument, aString is used as messageText, aParameter is passed
   756      The argument, aString is used as messageText, aParameter is passed
   775      The additional context is passed as the context responsible for the raise,
   758      The additional context is passed as the context responsible for the raise,
   776      allowing a raise to mimicri the exception happened somewhere else."
   759      allowing a raise to mimicri the exception happened somewhere else."
   777 
   760 
   778     <context: #return>
   761     <context: #return>
   779 
   762 
   780     ^ (self newException
   763     ^ self newException
   781           suspendedContext:aContext parameter:aParameter errorString:aString)
   764         raiseWith:aParameter errorString:aString in:aContext
   782           raise.
   765 
   783 
   766     "Created: / 23-07-1999 / 14:09:46 / stefan"
   784     "Modified: / 26.7.1996 / 16:29:42 / cg"
   767     "Modified: / 10-08-2010 / 10:03:19 / cg"
   785     "Modified: / 12.3.1998 / 15:20:12 / stefan"
       
   786     "Created: / 23.7.1999 / 14:09:46 / stefan"
       
   787 !
   768 !
   788 
   769 
   789 raiseWith:aParameter in:aContext
   770 raiseWith:aParameter in:aContext
   790     "raise a signal nonproceedable.
   771     "raise a signal nonproceedable.
   791      The argument, aParameter is passed as parameter.
   772      The argument, aParameter is passed as parameter.
   792      The additional context is passed as the context responsible for the raise,
   773      The additional context is passed as the context responsible for the raise,
   793      allowing a raise to mimicri the exception happened somewhere else."
   774      allowing a raise to mimicri the exception happened somewhere else."
   794 
   775 
   795     <context: #return>
   776     <context: #return>
   796 
   777 
   797     ^ (self newException
   778     ^ self newException
   798         suspendedContext:aContext parameter:aParameter)
   779         raiseWith:aParameter in:aContext
   799         raise.
   780 
       
   781     "Modified: / 10-08-2010 / 10:03:05 / cg"
   800 !
   782 !
   801 
   783 
   802 signalWith:messageText
   784 signalWith:messageText
   803     "ANSI compatibility"
   785     "ANSI compatibility"
   804 
   786 
   980 ! !
   962 ! !
   981 
   963 
   982 !Signal class methodsFor:'documentation'!
   964 !Signal class methodsFor:'documentation'!
   983 
   965 
   984 version
   966 version
   985     ^ '$Id: Signal.st 10544 2010-07-12 16:20:36Z vranyj1 $'
   967     ^ '$Id: Signal.st 10570 2010-08-26 10:12:57Z vranyj1 $'
   986 !
   968 !
   987 
   969 
   988 version_CVS
   970 version_CVS
   989     ^ 'Header: /cvs/stx/stx/libbasic/Signal.st,v 1.108 2009/10/01 07:38:26 cg Exp '
   971     ^ 'Header: /cvs/stx/stx/libbasic/Signal.st,v 1.109 2010/08/10 08:35:38 cg Exp '
   990 !
   972 !
   991 
   973 
   992 version_SVN
   974 version_SVN
   993     ^ '$Id: Signal.st 10544 2010-07-12 16:20:36Z vranyj1 $'
   975     ^ '$Id: Signal.st 10570 2010-08-26 10:12:57Z vranyj1 $'
   994 ! !
   976 ! !
   995 
   977 
   996 
   978 
   997 
   979 
       
   980