Updates from Tests, i.e. bug fixes
ExternalBytes subclass:#ExternalLong
instanceVariableNames:''
classVariableNames:''
poolDictionaries:''
category:'Database-ODBC-Driver'
!
!ExternalLong class methodsFor:'instance creation'!
new
^ super new:4
"
ExternalLong new
"
!
unprotectedNew
^ super unprotectedNew:4
"
ExternalLong new
"
! !
!ExternalLong methodsFor:'accessing'!
asBoolean
|result|
result := self byteAt:1.
result = 0 ifTrue:[
^ false.
].
^ true.
"
"
!
asInteger
^ self signedWordAt:1 MSB:false
"
ODBCLibrary::ExternalLong new value:10
"
!
asNullStatus
|result|
result := self wordAt:1 MSB:false.
result = 0 ifTrue:[
^ #SQL_NO_NULLS.
] ifFalse:[
result = 1 ifTrue:[
^ #SQL_NULLABLE.
] ifFalse:[
^ #SQL_NULLABLE_UNKNOWN
].
].
^ nil
!
boolean:bool
|result|
bool ifTrue:[self byteAt:1 put:1].
self byteAt:1 put:0.
!
value
^ self doubleWordAt:1
"
ODBCLibrary::ExternalLong new value:10
"
!
value:anInteger
self doubleWordAt:1 put:anInteger
! !
!ExternalLong class methodsFor:'documentation'!
version
^ '$Header: /cvs/stx/stx/libbasic2/ExternalLong.st,v 1.2 1998-01-28 16:22:27 dq Exp $'
! !