15 instantiations of SqlBinary
System.Data (15)
fx\src\data\Microsoft\SqlServer\Server\ValueUtilsSmi.cs (1)
3150
return new
SqlBinary
( buffer );
fx\src\data\System\Data\Common\SQLConvert.cs (1)
624
return new
SqlBinary
(Convert.FromBase64String((string)value));
fx\src\data\System\Data\Common\SQLTypes\SQLBinaryStorage.cs (1)
92
SqlBinary newValue = new
SqlBinary
();
fx\src\data\System\Data\Common\SQLTypes\SQLBytesStorage.cs (1)
91
SqlBinary newValue = new
SqlBinary
();
fx\src\data\System\Data\Sql\SqlMetaData.cs (2)
909
return new
SqlBinary
(rgbNewValue);
927
value = new
SqlBinary
(rgbNewValue);
fx\src\data\System\Data\SqlClient\SqlEnums.cs (1)
501
sqlVal = new
SqlBinary
((byte[])comVal);
fx\src\data\System\Data\SqlClient\TdsParser.cs (3)
5191
value.SqlBinary = new
SqlBinary
(unencryptedBytes, true); // doesn't copy the byte array
5362
value.SqlBinary = new
SqlBinary
(b, true); // doesn't copy the byte array
5622
value.SqlBinary = new
SqlBinary
(b, true); // doesn't copy the byte array
fx\src\data\System\Data\SQLTypes\SQLBinary.cs (4)
139
return new
SqlBinary
(x);
182
return new
SqlBinary
(rgbResult);
242
return x.IsNull ? SqlBinary.Null : new
SqlBinary
(x.ToByteArray());
524
public static readonly SqlBinary Null = new
SqlBinary
(true);
fx\src\data\System\Data\SQLTypes\SQLBytes.cs (1)
442
return IsNull ? SqlBinary.Null : new
SqlBinary
(Value);
167 references to SqlBinary
System.Data (167)
fx\src\data\Microsoft\SqlServer\Server\ITypedGetters.cs (1)
75
SqlBinary
GetSqlBinary( int ordinal );
fx\src\data\Microsoft\SqlServer\Server\ITypedSetters.cs (2)
79
void SetSqlBinary( int ordinal,
SqlBinary
value );
82
void SetSqlBinary( int ordinal,
SqlBinary
value, int offset );
fx\src\data\Microsoft\SqlServer\Server\MetadataUtilsSmi.cs (2)
114
ht.Add( typeof(
SqlBinary
), ExtendedClrTypeCode.SqlBinary );
217
else if (value.GetType() == typeof(
SqlBinary
))
fx\src\data\Microsoft\SqlServer\Server\SmiRecordBuffer.cs (3)
362
public virtual
SqlBinary
GetSqlBinary( int ordinal ) {
725
public virtual void SetSqlBinary( int ordinal,
SqlBinary
value )
735
public virtual void SetSqlBinary( int ordinal,
SqlBinary
value, int offset ) {
fx\src\data\Microsoft\SqlServer\Server\SmiRequestExecutor.cs (3)
420
public virtual
SqlBinary
GetSqlBinary( int ordinal ) {
783
public virtual void SetSqlBinary( int ordinal,
SqlBinary
value )
793
public virtual void SetSqlBinary( int ordinal,
SqlBinary
value, int offset ) {
fx\src\data\Microsoft\SqlServer\Server\SqlDataRecord.cs (2)
273
public virtual
SqlBinary
GetSqlBinary(int ordinal) {
553
public virtual void SetSqlBinary(int ordinal,
SqlBinary
value) {
fx\src\data\Microsoft\SqlServer\Server\ValueUtilsSmi.cs (17)
89
SqlBinary
value = (
SqlBinary
) obj;
307
internal static
SqlBinary
GetSqlBinary( SmiEventSink_Default sink, ITypedGettersV3 getters, int ordinal, SmiMetaData metaData ) {
310
return
SqlBinary
.Null;
318
return (
SqlBinary
) result;
373
SqlBinary
binaryVal = (
SqlBinary
) obj;
1085
SqlBinary
.Null, // SqlDbType.Binary
1091
SqlBinary
.Null, // SqlDbType.Image
1103
SqlBinary
.Null, // SqlDbType.Timestamp
1105
SqlBinary
.Null, // SqlDbType.VarBinary
1144
targetBuffer.SqlBinary =
SqlBinary
.Null;
1458
internal static void SetSqlBinary( SmiEventSink_Default sink, ITypedSettersV3 setters, int ordinal, SmiMetaData metaData,
SqlBinary
value ) {
1616
case ExtendedClrTypeCode.SqlBinary: SetSqlBinary_LengthChecked( sink, setters, ordinal, metaData, (
SqlBinary
) value, offset ); break;
2485
private static void SetSqlBinary_LengthChecked( SmiEventSink_Default sink, ITypedSettersV3 setters, int ordinal, SmiMetaData metaData,
SqlBinary
value, int offset ) {
3146
private static
SqlBinary
GetSqlBinary_Unchecked( SmiEventSink_Default sink, ITypedGettersV3 getters, int ordinal ) {
3377
private static void SetSqlBinary_Unchecked( SmiEventSink_Default sink, ITypedSettersV3 setters, int ordinal,
SqlBinary
value, int offset, int length ) {
fx\src\data\System\Data\ColumnTypeConverter.cs (1)
52
typeof(
SqlBinary
),
fx\src\data\System\Data\Common\DataStorage.cs (1)
99
typeof(
SqlBinary
),
fx\src\data\System\Data\Common\SQLConvert.cs (5)
347
public static
SqlBinary
ConvertToSqlBinary(object value) {
350
return
SqlBinary
.Null;
357
return (
SqlBinary
) value;
361
throw ExceptionBuilder.ConvertFailed(valueType, typeof(
SqlBinary
));
713
return Convert.ToBase64String(((
SqlBinary
)value).Value);
fx\src\data\System\Data\Common\SQLTypes\SQLBinaryStorage.cs (15)
22
private
SqlBinary
[] values;
25
: base(column, typeof(
SqlBinary
),
SqlBinary
.Null,
SqlBinary
.Null, StorageType.SqlBinary) {
47
throw ExprException.Overflow(typeof(
SqlBinary
));
57
return values[recordNo].CompareTo((
SqlBinary
)value);
84
SqlBinary
[] newValues = new
SqlBinary
[capacity];
92
SqlBinary
newValue = new SqlBinary();
101
return ((
SqlBinary
)tmp);
106
Debug.Assert((value.GetType() == typeof(
SqlBinary
)), "wrong input type");
117
return new
SqlBinary
[recordCount];
121
SqlBinary
[] typedStore = (
SqlBinary
[]) store;
127
values = (
SqlBinary
[]) store;
fx\src\data\System\Data\Common\SQLTypes\SQLBytesStorage.cs (2)
91
SqlBinary
newValue = new SqlBinary();
100
return (new SqlBytes((
SqlBinary
)tmp));
fx\src\data\System\Data\Sql\SqlMetaData.cs (7)
899
public
SqlBinary
Adjust(
SqlBinary
value) {
1076
else if (dataType == typeof(
SqlBinary
))
1077
value = this.Adjust((
SqlBinary
)value);
1190
else if (dataType == typeof(
SqlBinary
))
1193
SqlBinary
sb = ((
SqlBinary
) value);
fx\src\data\System\Data\SqlClient\SqlBuffer.cs (3)
427
internal
SqlBinary
SqlBinary {
430
return (
SqlBinary
)_object;
432
return (
SqlBinary
)this.SqlValue; // anything else we haven't thought of goes through boxing.
fx\src\data\System\Data\SqlClient\SqlDataReader.cs (2)
2289
virtual public
SqlBinary
GetSqlBinary(int i) {
2301
SqlBinary
data = _data[i].SqlBinary;
fx\src\data\System\Data\SqlClient\SqlDataReaderSmi.cs (1)
728
public override
SqlBinary
GetSqlBinary(int ordinal) {
fx\src\data\System\Data\SqlClient\SqlEnums.cs (11)
304
else if (dataType == typeof(
SqlBinary
))
392
else if (sqlType == typeof(
SqlBinary
)) return
SqlBinary
.Null;
436
else if (sqlVal is
SqlBinary
)
437
comVal = ((
SqlBinary
)sqlVal).Value;
718
(255, 255, -1, false, false, false, TdsEnums.SQLBIGBINARY, TdsEnums.SQLBIGBINARY, MetaTypeName.BINARY, typeof(System.Byte[]), typeof(
SqlBinary
), SqlDbType.Binary, DbType.Binary, 2);
722
(255, 255, -1, false, false, false, TdsEnums.SQLBIGBINARY, TdsEnums.SQLBIGBINARY, MetaTypeName.TIMESTAMP, typeof(System.Byte[]), typeof(
SqlBinary
), SqlDbType.Timestamp, DbType.Binary, 2);
725
(255, 255, -1, false, false, false, TdsEnums.SQLBIGVARBINARY, TdsEnums.SQLBIGVARBINARY, MetaTypeName.VARBINARY, typeof(System.Byte[]), typeof(
SqlBinary
), SqlDbType.VarBinary, DbType.Binary, 2);
728
(255, 255, -1, false, true, true, TdsEnums.SQLBIGVARBINARY, TdsEnums.SQLBIGVARBINARY, MetaTypeName.VARBINARY, typeof(System.Byte[]), typeof(
SqlBinary
), SqlDbType.VarBinary, DbType.Binary, 2);
734
(255, 255, -1, false, false, false, TdsEnums.SQLVARBINARY, TdsEnums.SQLBIGBINARY, ADP.StrEmpty, typeof(System.Byte[]), typeof(
SqlBinary
), TdsEnums.SmallVarBinary, DbType.Binary, 2);
737
(255, 255, -1, false, true, false, TdsEnums.SQLIMAGE, TdsEnums.SQLIMAGE, MetaTypeName.IMAGE, typeof(System.Byte[]), typeof(
SqlBinary
), SqlDbType.Image, DbType.Binary, 0);
fx\src\data\System\Data\SqlClient\SqlParameter.cs (5)
1669
if (value is
SqlBinary
) {
1670
return ((
SqlBinary
)value).Length;
1704
if (value is
SqlBinary
) {
1705
if (((
SqlBinary
) value).IsNull) // MDAC #79648
1708
return ((
SqlBinary
) value).Length;
fx\src\data\System\Data\SqlClient\TdsParser.cs (7)
4804
nullVal.SqlBinary =
SqlBinary
.Null;
9416
actualLengthInBytes = (isSqlType) ? ((
SqlBinary
)value).Length : ((byte[])value).Length;
9537
ccb = (isSqlType) ? ((
SqlBinary
)value).Length : ((byte[])value).Length;
9975
if (value is
SqlBinary
) {
9976
return stateObj.WriteByteArray(((
SqlBinary
)value).Value, actualLength, offset, canAccumulate:false);
10939
if (value is
SqlBinary
) {
10940
Buffer.BlockCopy(((
SqlBinary
)value).Value, offset, b, 0, actualLength);
fx\src\data\System\Data\SQLTypes\SQLBinary.cs (67)
49
/// Initializes a new instance of the <see cref='System.Data.SqlTypes.
SqlBinary
'/> class with a binary object to be stored.
64
/// Initializes a new instance of the <see cref='System.Data.SqlTypes.
SqlBinary
'/> class with a binary object to be stored. This constructor will not copy the value.
79
/// Gets whether or not <see cref='System.Data.SqlTypes.
SqlBinary
.Value'/> is null.
119
/// Gets the length in bytes of <see cref='System.Data.SqlTypes.
SqlBinary
.Value'/>.
135
/// Converts a binary object to a <see cref='System.Data.SqlTypes.
SqlBinary
'/>.
138
public static implicit operator
SqlBinary
(byte[] x) {
146
/// Converts a <see cref='System.Data.SqlTypes.
SqlBinary
'/> to a binary object.
149
public static explicit operator byte[](
SqlBinary
x) {
155
/// Returns a string describing a <see cref='System.Data.SqlTypes.
SqlBinary
'/> object.
170
/// Adds two instances of <see cref='System.Data.SqlTypes.
SqlBinary
'/> together.
174
public static
SqlBinary
operator +(
SqlBinary
x,
SqlBinary
y) {
236
/// Converts a <see cref='System.Data.SqlTypes.SqlGuid'/> to a <see cref='System.Data.SqlTypes.
SqlBinary
'/>
241
public static explicit operator
SqlBinary
(SqlGuid x) {
242
return x.IsNull ?
SqlBinary
.Null : new SqlBinary(x.ToByteArray());
250
/// Compares two instances of <see cref='System.Data.SqlTypes.
SqlBinary
'/> for
254
public static SqlBoolean operator==(
SqlBinary
x,
SqlBinary
y) {
263
/// Compares two instances of <see cref='System.Data.SqlTypes.
SqlBinary
'/>
267
public static SqlBoolean operator!=(
SqlBinary
x,
SqlBinary
y) {
273
/// Compares the first <see cref='System.Data.SqlTypes.
SqlBinary
'/> for being less than the
274
/// second <see cref='System.Data.SqlTypes.
SqlBinary
'/>.
277
public static SqlBoolean operator<(
SqlBinary
x,
SqlBinary
y) {
286
/// Compares the first <see cref='System.Data.SqlTypes.
SqlBinary
'/> for being greater than the second <see cref='System.Data.SqlTypes.
SqlBinary
'/>.
289
public static SqlBoolean operator>(
SqlBinary
x,
SqlBinary
y) {
298
/// Compares the first <see cref='System.Data.SqlTypes.
SqlBinary
'/> for being less than or equal to the second <see cref='System.Data.SqlTypes.
SqlBinary
'/>.
301
public static SqlBoolean operator<=(
SqlBinary
x,
SqlBinary
y) {
311
/// Compares the first <see cref='System.Data.SqlTypes.
SqlBinary
'/> for being greater than or equal the second <see cref='System.Data.SqlTypes.
SqlBinary
'/>.
314
public static SqlBoolean operator>=(
SqlBinary
x,
SqlBinary
y) {
327
public static
SqlBinary
Add(
SqlBinary
x,
SqlBinary
y) {
331
public static
SqlBinary
Concat(
SqlBinary
x,
SqlBinary
y) {
336
public static SqlBoolean Equals(
SqlBinary
x,
SqlBinary
y) {
341
public static SqlBoolean NotEquals(
SqlBinary
x,
SqlBinary
y) {
346
public static SqlBoolean LessThan(
SqlBinary
x,
SqlBinary
y) {
351
public static SqlBoolean GreaterThan(
SqlBinary
x,
SqlBinary
y) {
356
public static SqlBoolean LessThanOrEqual(
SqlBinary
x,
SqlBinary
y) {
361
public static SqlBoolean GreaterThanOrEqual(
SqlBinary
x,
SqlBinary
y) {
381
if (value is
SqlBinary
) {
382
SqlBinary
i = (
SqlBinary
)value;
386
throw ADP.WrongType(value.GetType(), typeof(
SqlBinary
));
389
public int CompareTo(
SqlBinary
value) {
407
if (!(value is
SqlBinary
)) {
411
SqlBinary
i = (
SqlBinary
)value;
520
/// the <see cref='System.Data.SqlTypes.
SqlBinary
.Value'/> property of an
521
/// instance of the <see cref='System.Data.SqlTypes.
SqlBinary
'/> class.
524
public static readonly
SqlBinary
Null = new SqlBinary(true);
fx\src\data\System\Data\SQLTypes\SQLBytes.cs (5)
128
public SqlBytes(
SqlBinary
value) : this(value.IsNull ? (byte[])null : value.Value) {
441
public
SqlBinary
ToSqlBinary() {
442
return IsNull ?
SqlBinary
.Null : new SqlBinary(Value);
450
public static explicit operator
SqlBinary
(SqlBytes value) {
455
public static explicit operator SqlBytes(
SqlBinary
value) {
fx\src\data\System\Data\SQLTypes\SQLGuid.cs (3)
199
public static explicit operator SqlGuid(
SqlBinary
x) {
294
public
SqlBinary
ToSqlBinary() {
295
return (
SqlBinary
)this;
fx\src\data\System\Data\SQLTypes\SQLString.cs (1)
994
return
SqlBinary
.HashByteArray(rgbSortKey, rgbSortKey.Length);
fx\src\data\System\Data\xmlsaver.cs (1)
242
if (type == typeof(
SqlBinary
))