private void Init(Uri uri, string uriBaseId, string parentKey, int offset, int length, string mimeType, string contents, IEnumerable<Hash> hashes, IDictionary<string, SerializedPropertyInfo> properties)
{
if (uri != null)
{
Uri = new Uri(uri.OriginalString, uri.IsAbsoluteUri ? UriKind.Absolute : UriKind.Relative);
}
UriBaseId = uriBaseId;
ParentKey = parentKey;
Offset = offset;
Length = length;
MimeType = mimeType;
Contents = contents;
if (hashes != null)
{
var destination_0 = new List<Hash>();
foreach (var value_0 in hashes)
{
if (value_0 == null)
{
destination_0.Add(null);
}
else
{
destination_0.Add(new Hash(value_0));
}
}
Hashes = destination_0;
}
if (properties != null)
{
Properties = new Dictionary<string, SerializedPropertyInfo>(properties);
}
}
}