You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Zero/ZeroLevel/Services/Serialization/IBinaryWriter.cs

81 lines
1.9 KiB

6 years ago
using System;
using System.Collections.Generic;
using System.IO;
using System.Net;
namespace ZeroLevel.Services.Serialization
{
public interface IBinaryWriter
6 years ago
: IDisposable
{
void WriteBoolean(bool val);
6 years ago
void WriteByte(byte val);
6 years ago
void WriteBytes(byte[] val);
6 years ago
void WriteDouble(double val);
6 years ago
void WriteFloat(float val);
6 years ago
void WriteInt32(Int32 number);
6 years ago
void WriteLong(Int64 number);
6 years ago
void WriteString(string line);
6 years ago
void WriteGuid(Guid guid);
6 years ago
void WriteDateTime(DateTime? datetime);
6 years ago
void WriteDecimal(Decimal number);
6 years ago
void WriteTimeSpan(TimeSpan period);
6 years ago
void WriteIP(IPAddress ip);
6 years ago
void WriteIPEndpoint(IPEndPoint endpoint);
#region Extensions
6 years ago
void WriteCollection<T>(IEnumerable<T> collection)
where T : IBinarySerializable;
6 years ago
void WriteCollection(IEnumerable<string> collection);
6 years ago
void WriteCollection(IEnumerable<Guid> collection);
6 years ago
void WriteCollection(IEnumerable<DateTime> collection);
6 years ago
void WriteCollection(IEnumerable<Int64> collection);
6 years ago
void WriteCollection(IEnumerable<Int32> collection);
6 years ago
void WriteCollection(IEnumerable<Double> collection);
6 years ago
void WriteCollection(IEnumerable<Decimal> collection);
void WriteCollection(IEnumerable<TimeSpan> collection);
void WriteCollection(IEnumerable<float> collection);
6 years ago
void WriteCollection(IEnumerable<bool> collection);
6 years ago
void WriteCollection(IEnumerable<byte> collection);
6 years ago
void WriteCollection(IEnumerable<byte[]> collection);
6 years ago
void WriteCollection(IEnumerable<IPEndPoint> collection);
6 years ago
void WriteCollection(IEnumerable<IPAddress> collection);
6 years ago
void Write<T>(T item)
where T : IBinarySerializable;
void WriteCompatible<T>(T item);
#endregion Extensions
6 years ago
Stream Stream { get; }
}
}

Powered by TurnKey Linux.