Removed BOM marker from some files.

Also removed some trailing whitespace.

Change-Id: I40bf4f776ca4d467b7ee6f2c9a7500c13700f9d5
parent c41a0453
/* /*
* Copyright 2014 Google Inc. All rights reserved. * Copyright 2014 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
......
...@@ -80,9 +80,9 @@ namespace FlatBuffers ...@@ -80,9 +80,9 @@ namespace FlatBuffers
/// <summary> /// <summary>
/// Gets and sets a Boolean to disable the optimization when serializing /// Gets and sets a Boolean to disable the optimization when serializing
/// default values to a Table. /// default values to a Table.
/// ///
/// In order to save space, fields that are set to their default value /// In order to save space, fields that are set to their default value
/// don't get serialized into the buffer. /// don't get serialized into the buffer.
/// </summary> /// </summary>
public bool ForceDefaults { get; set; } public bool ForceDefaults { get; set; }
...@@ -349,7 +349,7 @@ namespace FlatBuffers ...@@ -349,7 +349,7 @@ namespace FlatBuffers
/// and <see cref="ForceDefaults"/> is false, the value will be skipped.</param> /// and <see cref="ForceDefaults"/> is false, the value will be skipped.</param>
/// <param name="d">The default value to compare the value against</param> /// <param name="d">The default value to compare the value against</param>
public void AddBool(int o, bool x, bool d) { if (ForceDefaults || x != d) { AddBool(x); Slot(o); } } public void AddBool(int o, bool x, bool d) { if (ForceDefaults || x != d) { AddBool(x); Slot(o); } }
/// <summary> /// <summary>
/// Adds a SByte to the Table at index `o` in its vtable using the value `x` and default `d` /// Adds a SByte to the Table at index `o` in its vtable using the value `x` and default `d`
/// </summary> /// </summary>
...@@ -358,7 +358,7 @@ namespace FlatBuffers ...@@ -358,7 +358,7 @@ namespace FlatBuffers
/// and <see cref="ForceDefaults"/> is false, the value will be skipped.</param> /// and <see cref="ForceDefaults"/> is false, the value will be skipped.</param>
/// <param name="d">The default value to compare the value against</param> /// <param name="d">The default value to compare the value against</param>
public void AddSbyte(int o, sbyte x, sbyte d) { if (ForceDefaults || x != d) { AddSbyte(x); Slot(o); } } public void AddSbyte(int o, sbyte x, sbyte d) { if (ForceDefaults || x != d) { AddSbyte(x); Slot(o); } }
/// <summary> /// <summary>
/// Adds a Byte to the Table at index `o` in its vtable using the value `x` and default `d` /// Adds a Byte to the Table at index `o` in its vtable using the value `x` and default `d`
/// </summary> /// </summary>
......
/* /*
* Copyright 2014 Google Inc. All rights reserved. * Copyright 2014 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
......
/* /*
* Copyright 2014 Google Inc. All rights reserved. * Copyright 2014 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
...@@ -26,7 +26,7 @@ using System.Runtime.InteropServices; ...@@ -26,7 +26,7 @@ using System.Runtime.InteropServices;
[assembly: AssemblyConfiguration("")] [assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")] [assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("FlatBuffers")] [assembly: AssemblyProduct("FlatBuffers")]
[assembly: AssemblyCopyright("Copyright © 2015 Google Inc")] [assembly: AssemblyCopyright("Copyright (c) 2015 Google Inc")]
[assembly: AssemblyTrademark("")] [assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")] [assembly: AssemblyCulture("")]
......
/* /*
* Copyright 2014 Google Inc. All rights reserved. * Copyright 2014 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
......
/* /*
* Copyright 2014 Google Inc. All rights reserved. * Copyright 2014 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
......
/* /*
* Copyright 2014 Google Inc. All rights reserved. * Copyright 2014 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
......
/* /*
* Copyright 2016 Google Inc. All rights reserved. * Copyright 2016 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
......
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup> <PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
......
/* /*
* Copyright 2015 Google Inc. All rights reserved. * Copyright 2015 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
...@@ -124,13 +124,13 @@ namespace FlatBuffers.Test ...@@ -124,13 +124,13 @@ namespace FlatBuffers.Test
builder.CreateString("moop"); builder.CreateString("moop");
Assert.ArrayEqual(new byte[] Assert.ArrayEqual(new byte[]
{ {
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, // Padding to 32 bytes 0, 0, 0, 0, // Padding to 32 bytes
4, 0, 0, 0, 4, 0, 0, 0,
(byte)'m', (byte)'o', (byte)'o', (byte)'p', (byte)'m', (byte)'o', (byte)'o', (byte)'p',
0, 0, 0, 0, // zero terminator with 3 byte pad 0, 0, 0, 0, // zero terminator with 3 byte pad
3, 0, 0, 0, 3, 0, 0, 0,
(byte)'f', (byte)'o', (byte)'o', 0 (byte)'f', (byte)'o', (byte)'o', 0
}, builder.DataBuffer.Data); }, builder.DataBuffer.Data);
} }
...@@ -142,19 +142,19 @@ namespace FlatBuffers.Test ...@@ -142,19 +142,19 @@ namespace FlatBuffers.Test
builder.CreateString("\x01\x02\x03"); builder.CreateString("\x01\x02\x03");
Assert.ArrayEqual(new byte[] Assert.ArrayEqual(new byte[]
{ {
3, 0, 0, 0, 3, 0, 0, 0,
0x01, 0x02, 0x03, 0 0x01, 0x02, 0x03, 0
}, builder.DataBuffer.Data); // No padding }, builder.DataBuffer.Data); // No padding
builder.CreateString("\x04\x05\x06\x07"); builder.CreateString("\x04\x05\x06\x07");
Assert.ArrayEqual(new byte[] Assert.ArrayEqual(new byte[]
{ {
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, // Padding to 32 bytes 0, 0, 0, 0, // Padding to 32 bytes
4, 0, 0, 0, 4, 0, 0, 0,
0x04, 0x05, 0x06, 0x07, 0x04, 0x05, 0x06, 0x07,
0, 0, 0, 0, // zero terminator with 3 byte pad 0, 0, 0, 0, // zero terminator with 3 byte pad
3, 0, 0, 0, 3, 0, 0, 0,
0x01, 0x02, 0x03, 0 0x01, 0x02, 0x03, 0
}, builder.DataBuffer.Data); // No padding }, builder.DataBuffer.Data); // No padding
} }
...@@ -168,9 +168,9 @@ namespace FlatBuffers.Test ...@@ -168,9 +168,9 @@ namespace FlatBuffers.Test
builder.EndObject(); builder.EndObject();
Assert.ArrayEqual(new byte[] Assert.ArrayEqual(new byte[]
{ {
4, 0, 4, 0, 4, 0, 4, 0,
4, 0, 0, 0 4, 0, 0, 0
}, },
builder.DataBuffer.Data); builder.DataBuffer.Data);
} }
...@@ -287,20 +287,20 @@ namespace FlatBuffers.Test ...@@ -287,20 +287,20 @@ namespace FlatBuffers.Test
var vecEnd = builder.EndVector(); var vecEnd = builder.EndVector();
builder.StartObject(1); builder.StartObject(1);
builder.AddOffset(0, vecEnd.Value, 0); builder.AddOffset(0, vecEnd.Value, 0);
builder.EndObject(); builder.EndObject();
Assert.ArrayEqual(new byte[] Assert.ArrayEqual(new byte[]
{ {
0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0,
0, 0, // Padding to 32 bytes 0, 0, // Padding to 32 bytes
6, 0, // vtable bytes 6, 0, // vtable bytes
8, 0, // object length inc vtable offset 8, 0, // object length inc vtable offset
4, 0, // start of vector offset value 0 4, 0, // start of vector offset value 0
6, 0, 0, 0, // int32 offset for start of vtable 6, 0, 0, 0, // int32 offset for start of vtable
4, 0, 0, 0, 4, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
}, },
builder.DataBuffer.Data); builder.DataBuffer.Data);
...@@ -320,7 +320,7 @@ namespace FlatBuffers.Test ...@@ -320,7 +320,7 @@ namespace FlatBuffers.Test
Assert.ArrayEqual(new byte[] Assert.ArrayEqual(new byte[]
{ {
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, // Padding to 32 bytes 0, 0, 0, 0, // Padding to 32 bytes
8, 0, // vtable bytes 8, 0, // vtable bytes
12, 0, // object length inc vtable offset 12, 0, // object length inc vtable offset
10, 0, // offset to int16 value 0 10, 0, // offset to int16 value 0
...@@ -349,9 +349,9 @@ namespace FlatBuffers.Test ...@@ -349,9 +349,9 @@ namespace FlatBuffers.Test
builder.EndObject(); builder.EndObject();
Assert.ArrayEqual(new byte[] Assert.ArrayEqual(new byte[]
{ {
0, 0, 0, 0, // Padding to 32 bytes 0, 0, 0, 0, // Padding to 32 bytes
8, 0, // vtable bytes 8, 0, // vtable bytes
12, 0, // object length 12, 0, // object length
6, 0, // start of value 0 from end of vtable 6, 0, // start of value 0 from end of vtable
8, 0, // start of value 1 from end of buffer 8, 0, // start of value 1 from end of buffer
8, 0, 0, 0, // int32 offset for start of vtable 8, 0, 0, 0, // int32 offset for start of vtable
...@@ -382,9 +382,9 @@ namespace FlatBuffers.Test ...@@ -382,9 +382,9 @@ namespace FlatBuffers.Test
{ {
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, // Padding to 32 bytes 0, 0, // Padding to 32 bytes
6, 0, // vtable bytes 6, 0, // vtable bytes
16, 0, // object length 16, 0, // object length
4, 0, // start of struct from here 4, 0, // start of struct from here
6, 0, 0, 0, // int32 offset for start of vtable 6, 0, 0, 0, // int32 offset for start of vtable
0x78, 0x56, 0x34, 0x12, // struct value 2 0x78, 0x56, 0x34, 0x12, // struct value 2
...@@ -413,9 +413,9 @@ namespace FlatBuffers.Test ...@@ -413,9 +413,9 @@ namespace FlatBuffers.Test
{ {
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, // Padding to 32 bytes 0, 0, // Padding to 32 bytes
6, 0, // vtable bytes 6, 0, // vtable bytes
8, 0, // object length 8, 0, // object length
4, 0, // offset of vector offset 4, 0, // offset of vector offset
6, 0, 0, 0, // int32 offset for start of vtable 6, 0, 0, 0, // int32 offset for start of vtable
4, 0, 0, 0, // Vector start offset 4, 0, 0, 0, // Vector start offset
...@@ -442,16 +442,16 @@ namespace FlatBuffers.Test ...@@ -442,16 +442,16 @@ namespace FlatBuffers.Test
{ {
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, //Padding to 32 bytes 0, 0, 0, 0, //Padding to 32 bytes
12, 0, 0, 0, // root of table, pointing to vtable offset 12, 0, 0, 0, // root of table, pointing to vtable offset
8, 0, // vtable bytes 8, 0, // vtable bytes
8, 0, // object length 8, 0, // object length
7, 0, // start of value 0 7, 0, // start of value 0
4, 0, // start of value 1 4, 0, // start of value 1
8, 0, 0, 0, // int32 offset for start of vtable 8, 0, 0, 0, // int32 offset for start of vtable
66, 0, // value 1 66, 0, // value 1
0, 33, // value 0 0, 33, // value 0
}, },
builder.DataBuffer.Data); builder.DataBuffer.Data);
} }
...@@ -480,23 +480,23 @@ namespace FlatBuffers.Test ...@@ -480,23 +480,23 @@ namespace FlatBuffers.Test
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, // padding to 64 bytes 0, 0, 0, 0, // padding to 64 bytes
16, 0, 0, 0, // root of table, pointing to vtable offset (obj1) 16, 0, 0, 0, // root of table, pointing to vtable offset (obj1)
0, 0, // padding 0, 0, // padding
10, 0, // vtable bytes 10, 0, // vtable bytes
8, 0, // object length 8, 0, // object length
7, 0, // start of value 0 7, 0, // start of value 0
6, 0, // start of value 1 6, 0, // start of value 1
5, 0, // start of value 2 5, 0, // start of value 2
10, 0, 0, 0, // int32 offset for start of vtable 10, 0, 0, 0, // int32 offset for start of vtable
0, // pad 0, // pad
77, // values 2, 1, 0 77, // values 2, 1, 0
66, 66,
55, 55,
12, 0, 0, 0, // root of table, pointing to vtable offset (obj0) 12, 0, 0, 0, // root of table, pointing to vtable offset (obj0)
8, 0, // vtable bytes 8, 0, // vtable bytes
8, 0, // object length 8, 0, // object length
7, 0, // start of value 0 7, 0, // start of value 0
6, 0, // start of value 1 6, 0, // start of value 1
8, 0, 0, 0, // int32 offset for start of vtable 8, 0, 0, 0, // int32 offset for start of vtable
...@@ -531,7 +531,7 @@ namespace FlatBuffers.Test ...@@ -531,7 +531,7 @@ namespace FlatBuffers.Test
24, 0, 0, 0, // root of table, pointing to vtable offset (obj0) 24, 0, 0, 0, // root of table, pointing to vtable offset (obj0)
20, 0, // vtable bytes 20, 0, // vtable bytes
12, 0, // object length 12, 0, // object length
11, 0, // start of value 0 11, 0, // start of value 0
10, 0, // start of value 1 10, 0, // start of value 1
9, 0, // start of value 2 9, 0, // start of value 2
...@@ -542,10 +542,10 @@ namespace FlatBuffers.Test ...@@ -542,10 +542,10 @@ namespace FlatBuffers.Test
4, 0, // start of value 7 4, 0, // start of value 7
20, 0, 0, 0, // int32 offset for start of vtable 20, 0, 0, 0, // int32 offset for start of vtable
1, 1, 1, 1, // values 1, 1, 1, 1, // values
1, 1, 1, 1, 1, 1, 1, 1,
}, },
builder.DataBuffer.Data); builder.DataBuffer.Data);
} }
...@@ -557,17 +557,17 @@ namespace FlatBuffers.Test ...@@ -557,17 +557,17 @@ namespace FlatBuffers.Test
builder.StartObject(1); builder.StartObject(1);
builder.AddFloat(0, 1, 0); builder.AddFloat(0, 1, 0);
builder.EndObject(); builder.EndObject();
Assert.ArrayEqual(new byte[] Assert.ArrayEqual(new byte[]
{ {
0, 0, 0, 0,
6, 0, // vtable bytes 6, 0, // vtable bytes
8, 0, // object length 8, 0, // object length
4, 0, // start of value 0 4, 0, // start of value 0
6, 0, 0, 0, // int32 offset for start of vtable 6, 0, 0, 0, // int32 offset for start of vtable
0, 0, 128, 63, // value 0, 0, 128, 63, // value
}, },
builder.DataBuffer.Data); builder.DataBuffer.Data);
} }
...@@ -660,7 +660,7 @@ namespace FlatBuffers.Test ...@@ -660,7 +660,7 @@ namespace FlatBuffers.Test
} }
_lcg.Reset(); _lcg.Reset();
// Test all objects are readable and return expected values... // Test all objects are readable and return expected values...
for (var i = 0; i < objectCount; ++i) for (var i = 0; i < objectCount; ++i)
{ {
......
/* /*
* Copyright 2016 Google Inc. All rights reserved. * Copyright 2016 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
......
/* /*
* Copyright 2016 Google Inc. All rights reserved. * Copyright 2016 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
......
/* /*
* Copyright 2016 Google Inc. All rights reserved. * Copyright 2016 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
......
/* /*
* Copyright 2014 Google Inc. All rights reserved. * Copyright 2014 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
......
/* /*
* Copyright 2014 Google Inc. All rights reserved. * Copyright 2014 Google Inc. All rights reserved.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
...@@ -26,7 +26,7 @@ using System.Runtime.InteropServices; ...@@ -26,7 +26,7 @@ using System.Runtime.InteropServices;
[assembly: AssemblyConfiguration("")] [assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")] [assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("FlatBuffers.Test")] [assembly: AssemblyProduct("FlatBuffers.Test")]
[assembly: AssemblyCopyright("Copyright © 2014 Google Inc")] [assembly: AssemblyCopyright("Copyright (c) 2014 Google Inc")]
[assembly: AssemblyTrademark("")] [assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")] [assembly: AssemblyCulture("")]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment