diff --git a/DocFX/articles/coding-conventions.md b/DocFX/articles/coding-conventions.md
index 9185ce572..1f1de2a5a 100644
--- a/DocFX/articles/coding-conventions.md
+++ b/DocFX/articles/coding-conventions.md
@@ -8,19 +8,24 @@ demonstrates many of the coding conventions within Sensus. These must be strictl
The start of every source code file must contain the following copyright notice:
- // Copyright 2014 The Rector & Visitors of the University of Virginia
- //
- // Licensed under the Apache License, Version 2.0 (the "License");
- // you may not use this file except in compliance with the License.
- // You may obtain a copy of the License at
- //
- // http://www.apache.org/licenses/LICENSE-2.0
- //
- // Unless required by applicable law or agreed to in writing, software
- // distributed under the License is distributed on an "AS IS" BASIS,
- // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- // See the License for the specific language governing permissions and
- // limitations under the License.
+ //Copyright 2014 The Rector & Visitors of the University of Virginia
+ //
+ //Permission is hereby granted, free of charge, to any person obtaining a copy
+ //of this software and associated documentation files (the "Software"), to deal
+ //in the Software without restriction, including without limitation the rights
+ //to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ //copies of the Software, and to permit persons to whom the Software is
+ //furnished to do so, subject to the following conditions:
+ //
+ //The above copyright notice and this permission notice shall be included in
+ //all copies or substantial portions of the Software.
+ //
+ //THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+ //INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+ //PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ //HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+ //OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ //SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Next is a blank line followed by the `using` declarations:
diff --git a/ExampleScriptProbeAgent.Shared/ExampleAdaptiveScriptProbeAgent.cs b/ExampleScriptProbeAgent.Shared/ExampleAdaptiveScriptProbeAgent.cs
index 101a8d8d7..c81535437 100644
--- a/ExampleScriptProbeAgent.Shared/ExampleAdaptiveScriptProbeAgent.cs
+++ b/ExampleScriptProbeAgent.Shared/ExampleAdaptiveScriptProbeAgent.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading.Tasks;
@@ -149,4 +154,4 @@ public override string ToString()
return Id + ": " + Description;
}
}
-}
\ No newline at end of file
+}
diff --git a/ExampleScriptProbeAgent.Shared/ExampleRandomScriptProbeAgent.cs b/ExampleScriptProbeAgent.Shared/ExampleRandomScriptProbeAgent.cs
index 9ba96a75a..1f3760c66 100644
--- a/ExampleScriptProbeAgent.Shared/ExampleRandomScriptProbeAgent.cs
+++ b/ExampleScriptProbeAgent.Shared/ExampleRandomScriptProbeAgent.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading.Tasks;
@@ -105,4 +110,4 @@ public override string ToString()
return Id + ": " + Description;
}
}
-}
\ No newline at end of file
+}
diff --git a/ExampleScriptProbeAgent/Properties/AssemblyInfo.cs b/ExampleScriptProbeAgent/Properties/AssemblyInfo.cs
index 0245a6931..8143ba7b2 100644
--- a/ExampleScriptProbeAgent/Properties/AssemblyInfo.cs
+++ b/ExampleScriptProbeAgent/Properties/AssemblyInfo.cs
@@ -1,4 +1,22 @@
-using System.Reflection;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+using System.Reflection;
using System.Runtime.CompilerServices;
// Information about this assembly is defined by the following attributes.
diff --git a/LICENSE.txt b/LICENSE.txt
index fe8229ff5..e535a15ee 100644
--- a/LICENSE.txt
+++ b/LICENSE.txt
@@ -1,202 +1,18 @@
-Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "{}"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright 2014 The Rector & Visitors of the University of Virginia
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/Sensus.Android.Shared/AndroidActivityResultRequestCode.cs b/Sensus.Android.Shared/AndroidActivityResultRequestCode.cs
index de0ec6e61..b66cc61a3 100644
--- a/Sensus.Android.Shared/AndroidActivityResultRequestCode.cs
+++ b/Sensus.Android.Shared/AndroidActivityResultRequestCode.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Android
{
diff --git a/Sensus.Android.Shared/AndroidPowerConnectionChangeBroadcastReceiver.cs b/Sensus.Android.Shared/AndroidPowerConnectionChangeBroadcastReceiver.cs
index 113f8d127..7c54a8954 100644
--- a/Sensus.Android.Shared/AndroidPowerConnectionChangeBroadcastReceiver.cs
+++ b/Sensus.Android.Shared/AndroidPowerConnectionChangeBroadcastReceiver.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Content;
using Sensus.Exceptions;
@@ -46,4 +51,4 @@ public override void OnReceive(global::Android.Content.Context context, Intent i
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/AndroidPowerConnectionChangeListener.cs b/Sensus.Android.Shared/AndroidPowerConnectionChangeListener.cs
index fc4e364eb..86738c7b1 100644
--- a/Sensus.Android.Shared/AndroidPowerConnectionChangeListener.cs
+++ b/Sensus.Android.Shared/AndroidPowerConnectionChangeListener.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Exceptions;
@@ -34,4 +39,4 @@ public AndroidPowerConnectionChangeListener()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/AndroidSensusService.cs b/Sensus.Android.Shared/AndroidSensusService.cs
index a0fb491fd..7c0b4d9b6 100644
--- a/Sensus.Android.Shared/AndroidSensusService.cs
+++ b/Sensus.Android.Shared/AndroidSensusService.cs
@@ -1,320 +1,325 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using Android.App;
-using Android.Content;
-using Android.OS;
-using System;
-using System.Collections.Generic;
-using Sensus.Context;
-using Sensus.Android.Context;
-using Sensus.Android.Callbacks;
-using Sensus.Android.Concurrent;
-using Sensus.Encryption;
-using System.Linq;
-using System.Threading.Tasks;
-using Sensus.Android.Notifications;
-
-// the unit test project contains the Resource class in its namespace rather than the Sensus.Android
-// namespace. include that namespace below.
-#if UNIT_TEST
-using Sensus.Android.Tests;
-#endif
-
-namespace Sensus.Android
-{
- ///
- /// Android sensus service. Manages background running of Sensus. This is a hybrid service (http://developer.android.com/guide/components/services.html), in that
- /// it is started by the Sensus activity to run indefinitely, but the activity also binds to it to manage the Sensus system (e.g., creating protocols, starting
- /// and stopping them, etc.). For now, nobody other than the Sensus activity can interact with the service (Exported = false). Perhaps we'll allow this in the future
- /// to support integration with other apps.
- ///
- [Service(Exported = false, Label = "Runs the Sensus mobile sensing application.")]
- public class AndroidSensusService : Service
- {
- public const int FOREGROUND_SERVICE_NOTIFICATION_ID = 1;
- public const string FROM_ON_BOOT_KEY = "from-on-boot";
-
- public static Intent StartService(global::Android.Content.Context context, bool fromOnBoot)
- {
- Intent serviceIntent = new Intent(context, typeof(AndroidSensusService));
- serviceIntent.PutExtra(FROM_ON_BOOT_KEY, fromOnBoot);
-
- // after android 26, starting a foreground service requires the use of StartForegroundService rather than StartService.
- // in either case, the service itself will call StartForeground after it has started. more info:
- //
- // https://developer.android.com/reference/android/content/Context.html#startForegroundService(android.content.Intent)
- //
- // also see notes on backwards compatibility for how the compiler directives are used below:
- //
- // see the Backwards Compatibility article for more information
-#if __ANDROID_26__
- if (Build.VERSION.SdkInt >= BuildVersionCodes.O)
- {
- context.StartForegroundService(serviceIntent);
- }
- else
-#endif
- {
- context.StartService(serviceIntent);
- }
-
- return serviceIntent;
- }
-
- private readonly List _bindings = new List();
- private Notification.Builder _foregroundServiceNotificationBuilder;
- private AndroidPowerConnectionChangeBroadcastReceiver _powerBroadcastReceiver;
-
- public override void OnCreate()
- {
- base.OnCreate();
-
- SensusContext.Current = new AndroidSensusContext
- {
- Platform = Platform.Android,
- MainThreadSynchronizer = new MainConcurrent(),
- SymmetricEncryption = new SymmetricEncryption(SensusServiceHelper.ENCRYPTION_KEY),
- CallbackScheduler = new AndroidCallbackScheduler(this),
- Notifier = new AndroidNotifier(this),
- PowerConnectionChangeListener = new AndroidPowerConnectionChangeListener()
- };
-
- // promote this service to a foreground service as soon as possible. we use a foreground service for several
- // reasons. it's honest and transparent. it lets us work effectively with the android 8.0 restrictions on
- // background services. we can run forever without being killed. we receive background location updates, etc.
- PendingIntent mainActivityPendingIntent = PendingIntent.GetActivity(this, 0, new Intent(this, typeof(AndroidMainActivity)), 0);
- _foregroundServiceNotificationBuilder = (SensusContext.Current.Notifier as AndroidNotifier).CreateNotificationBuilder(this, AndroidNotifier.SensusNotificationChannel.ForegroundService)
- .SetSmallIcon(Resource.Drawable.ic_launcher)
- .SetContentIntent(mainActivityPendingIntent)
- .SetOngoing(true);
- UpdateForegroundServiceNotificationBuilder();
- StartForeground(FOREGROUND_SERVICE_NOTIFICATION_ID, _foregroundServiceNotificationBuilder.Build());
-
- // https://developer.android.com/reference/android/content/Intent#ACTION_POWER_CONNECTED
- // This is intended for applications that wish to register specifically to this notification. Unlike ACTION_BATTERY_CHANGED,
- // applications will be woken for this and so do not have to stay active to receive this notification. This action can be
- // used to implement actions that wait until power is available to trigger.
- //
- // We use the same receiver for both the connected and disconnected intents.
- _powerBroadcastReceiver = new AndroidPowerConnectionChangeBroadcastReceiver();
- IntentFilter powerConnectFilter = new IntentFilter();
- powerConnectFilter.AddAction(Intent.ActionPowerConnected);
- powerConnectFilter.AddAction(Intent.ActionPowerDisconnected);
- powerConnectFilter.AddCategory(Intent.CategoryDefault);
- RegisterReceiver(_powerBroadcastReceiver, powerConnectFilter);
-
- // must come after context initialization. also, it is here -- below StartForeground -- because it can
- // take a while to complete and we don't want to run afoul of the short timing requirements on calling
- // StartForeground.
- SensusServiceHelper.Initialize(() => new AndroidSensusServiceHelper());
-
- AndroidSensusServiceHelper serviceHelper = SensusServiceHelper.Get() as AndroidSensusServiceHelper;
-
- // we might have failed to create the service helper. it's also happened that the service is created after the
- // service helper is disposed: https://insights.xamarin.com/app/Sensus-Production/issues/46
- if (serviceHelper == null)
- {
- Stop();
- }
- else
- {
- serviceHelper.SetService(this);
- }
- }
-
- public override StartCommandResult OnStartCommand(Intent intent, StartCommandFlags flags, int startId)
- {
- AndroidSensusServiceHelper serviceHelper = SensusServiceHelper.Get() as AndroidSensusServiceHelper;
-
- // there might be a race condition between the calling of this method and the stopping/disposal of the service helper.
- // if the service helper is stopped/disposed before the service is stopped but after this method is called (e.g., by
- // an alarm callback), the service helper will be null.
- if (serviceHelper != null)
- {
- serviceHelper.Logger.Log("Sensus service received start command (startId=" + startId + ", flags=" + flags + ").", LoggingLevel.Normal, GetType());
-
- // update the foreground service notification with information about loaded/running studies.
- ReissueForegroundServiceNotification();
-
- // if we started from the on-boot signal and there are no running protocols, stop the app now. there is no reason for
- // the app to be running in this situation, and the user will likely be annoyed at the presence of the foreground
- // service notification.
- if (intent != null && intent.GetBooleanExtra(FROM_ON_BOOT_KEY, false) && serviceHelper.RunningProtocolIds.Count == 0)
- {
- serviceHelper.Logger.Log("Started from on-boot signal without running protocols. Stopping service now.", LoggingLevel.Normal, GetType());
- Stop();
- return StartCommandResult.NotSticky;
- }
-
- // acquire wake lock before this method returns to ensure that the device does not sleep prematurely, interrupting the execution of a callback.
- serviceHelper.KeepDeviceAwake();
-
- Task.Run(async () =>
- {
- // the service can be stopped without destroying the service object. in such cases,
- // subsequent calls to start the service will not call OnCreate. therefore, it's
- // important that any code called here is okay to call multiple times, even if the
- // service is running. calling this when the service is running can happen because
- // sensus receives a signal on device boot and for any callback alarms that are
- // requested. furthermore, all calls here should be nonblocking / async so we don't
- // tie up the UI thread.
- await serviceHelper.StartAsync();
-
- if (intent == null)
- {
- serviceHelper.LetDeviceSleep();
- }
- else
- {
- AndroidCallbackScheduler callbackScheduler = SensusContext.Current.CallbackScheduler as AndroidCallbackScheduler;
-
- // is this a callback intent?
- if (callbackScheduler.IsCallback(intent))
- {
- // service the callback -- the matching LetDeviceSleep will be called therein
- await callbackScheduler.ServiceCallbackAsync(intent);
- }
- else
- {
- serviceHelper.LetDeviceSleep();
- }
- }
- });
- }
-
- // if the service is killed by the system (e.g., due to resource constraints), ask the system to restart
- // the service when possible.
- return StartCommandResult.Sticky;
- }
-
- ///
- /// Updates the foreground service notification builder, so that it reflects the enrollment status and participation level of the user.
- ///
- private void UpdateForegroundServiceNotificationBuilder()
- {
- AndroidSensusServiceHelper serviceHelper = SensusServiceHelper.Get() as AndroidSensusServiceHelper;
-
- // the service helper will be null when this method is called from OnCreate. set some generic text until
- // the service helper has a chance to load, at which time this method will be called again and we'll update
- // the notification with more detailed information.
- if (serviceHelper == null)
- {
- _foregroundServiceNotificationBuilder.SetContentTitle("Starting...");
- _foregroundServiceNotificationBuilder.SetContentText("Tap to Open Sensus.");
- }
- // after the service helper has been initialized, we'll have more information about the studies.
- else
- {
- int numRunningStudies = serviceHelper.RunningProtocolIds.Count;
- _foregroundServiceNotificationBuilder.SetContentTitle("You are enrolled in " + numRunningStudies + " " + (numRunningStudies == 1 ? "study" : "studies") + ".");
-
- string contentText = "";
-
- // although the number of studies might be greater than 0, the protocols might not yet be started (e.g., after starting sensus).
- List runningProtocols = serviceHelper.GetRunningProtocols();
- if (runningProtocols.Count > 0)
- {
- double avgParticipation = runningProtocols.Average(protocol => protocol.Participation) * 100;
- contentText += "Your overall participation level is " + Math.Round(avgParticipation, 0) + "%. ";
- }
-
- contentText += "Tap to open Sensus.";
-
- _foregroundServiceNotificationBuilder.SetContentText(contentText);
- }
- }
-
- public void ReissueForegroundServiceNotification()
- {
- UpdateForegroundServiceNotificationBuilder();
- (GetSystemService(NotificationService) as NotificationManager).Notify(FOREGROUND_SERVICE_NOTIFICATION_ID, _foregroundServiceNotificationBuilder.Build());
- }
-
- public override IBinder OnBind(Intent intent)
- {
- AndroidSensusServiceBinder binder = new AndroidSensusServiceBinder(SensusServiceHelper.Get() as AndroidSensusServiceHelper);
-
- lock (_bindings)
- {
- _bindings.Add(binder);
- }
-
- return binder;
- }
-
- public void Stop()
- {
- NotifyBindingsOfStop();
- StopSelf();
- }
-
- private void NotifyBindingsOfStop()
- {
- // let everyone who is bound to the service know that we're going to stop.
- lock (_bindings)
- {
- foreach (AndroidSensusServiceBinder binder in _bindings)
- {
- if (binder.SensusServiceHelper != null && binder.ServiceStopAction != null)
- {
- try
- {
- binder.ServiceStopAction();
- }
- catch (Exception)
- {
- }
- }
- }
-
- _bindings.Clear();
- }
- }
-
- public override async void OnDestroy()
- {
- Console.Error.WriteLine("--------------------------- Destroying Service ---------------------------");
-
- AndroidSensusServiceHelper serviceHelper = SensusServiceHelper.Get() as AndroidSensusServiceHelper;
-
- // the service helper will be null if we failed to create it within OnCreate, so first check that. also,
- // OnDestroy can be called either when the user stops Sensus (in Android) and when the system reclaims
- // the service under memory pressure. in the former case, we'll already have done the notification and
- // stopping of protocols; however, we have no way to know how we reached OnDestroy, so to cover the latter
- // case we're going to do the notification and stopping again. this will be duplicative in the case where
- // the user has stopped sensus. in sum, anything we do below must be safe to run repeatedly.
- if (serviceHelper != null)
- {
- serviceHelper.Logger.Log("Destroying service.", LoggingLevel.Normal, GetType());
- NotifyBindingsOfStop();
- await serviceHelper.StopProtocolsAsync();
- serviceHelper.SetService(null);
- }
-
- // we've seen cases where the receiver doesn't get registered before the service is
- // destroyed. catch exception raised from attempting to unregister a receiver that
- // hasn't been registered.
- try
- {
- UnregisterReceiver(_powerBroadcastReceiver);
- }
- catch (Exception)
- { }
-
- // do this last so that we don't dispose the service and its system services too early.
- base.OnDestroy();
- }
- }
-}
\ No newline at end of file
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using Android.App;
+using Android.Content;
+using Android.OS;
+using System;
+using System.Collections.Generic;
+using Sensus.Context;
+using Sensus.Android.Context;
+using Sensus.Android.Callbacks;
+using Sensus.Android.Concurrent;
+using Sensus.Encryption;
+using System.Linq;
+using System.Threading.Tasks;
+using Sensus.Android.Notifications;
+
+// the unit test project contains the Resource class in its namespace rather than the Sensus.Android
+// namespace. include that namespace below.
+#if UNIT_TEST
+using Sensus.Android.Tests;
+#endif
+
+namespace Sensus.Android
+{
+ ///
+ /// Android sensus service. Manages background running of Sensus. This is a hybrid service (http://developer.android.com/guide/components/services.html), in that
+ /// it is started by the Sensus activity to run indefinitely, but the activity also binds to it to manage the Sensus system (e.g., creating protocols, starting
+ /// and stopping them, etc.). For now, nobody other than the Sensus activity can interact with the service (Exported = false). Perhaps we'll allow this in the future
+ /// to support integration with other apps.
+ ///
+ [Service(Exported = false, Label = "Runs the Sensus mobile sensing application.")]
+ public class AndroidSensusService : Service
+ {
+ public const int FOREGROUND_SERVICE_NOTIFICATION_ID = 1;
+ public const string FROM_ON_BOOT_KEY = "from-on-boot";
+
+ public static Intent StartService(global::Android.Content.Context context, bool fromOnBoot)
+ {
+ Intent serviceIntent = new Intent(context, typeof(AndroidSensusService));
+ serviceIntent.PutExtra(FROM_ON_BOOT_KEY, fromOnBoot);
+
+ // after android 26, starting a foreground service requires the use of StartForegroundService rather than StartService.
+ // in either case, the service itself will call StartForeground after it has started. more info:
+ //
+ // https://developer.android.com/reference/android/content/Context.html#startForegroundService(android.content.Intent)
+ //
+ // also see notes on backwards compatibility for how the compiler directives are used below:
+ //
+ // see the Backwards Compatibility article for more information
+#if __ANDROID_26__
+ if (Build.VERSION.SdkInt >= BuildVersionCodes.O)
+ {
+ context.StartForegroundService(serviceIntent);
+ }
+ else
+#endif
+ {
+ context.StartService(serviceIntent);
+ }
+
+ return serviceIntent;
+ }
+
+ private readonly List _bindings = new List();
+ private Notification.Builder _foregroundServiceNotificationBuilder;
+ private AndroidPowerConnectionChangeBroadcastReceiver _powerBroadcastReceiver;
+
+ public override void OnCreate()
+ {
+ base.OnCreate();
+
+ SensusContext.Current = new AndroidSensusContext
+ {
+ Platform = Platform.Android,
+ MainThreadSynchronizer = new MainConcurrent(),
+ SymmetricEncryption = new SymmetricEncryption(SensusServiceHelper.ENCRYPTION_KEY),
+ CallbackScheduler = new AndroidCallbackScheduler(this),
+ Notifier = new AndroidNotifier(this),
+ PowerConnectionChangeListener = new AndroidPowerConnectionChangeListener()
+ };
+
+ // promote this service to a foreground service as soon as possible. we use a foreground service for several
+ // reasons. it's honest and transparent. it lets us work effectively with the android 8.0 restrictions on
+ // background services. we can run forever without being killed. we receive background location updates, etc.
+ PendingIntent mainActivityPendingIntent = PendingIntent.GetActivity(this, 0, new Intent(this, typeof(AndroidMainActivity)), 0);
+ _foregroundServiceNotificationBuilder = (SensusContext.Current.Notifier as AndroidNotifier).CreateNotificationBuilder(this, AndroidNotifier.SensusNotificationChannel.ForegroundService)
+ .SetSmallIcon(Resource.Drawable.ic_launcher)
+ .SetContentIntent(mainActivityPendingIntent)
+ .SetOngoing(true);
+ UpdateForegroundServiceNotificationBuilder();
+ StartForeground(FOREGROUND_SERVICE_NOTIFICATION_ID, _foregroundServiceNotificationBuilder.Build());
+
+ // https://developer.android.com/reference/android/content/Intent#ACTION_POWER_CONNECTED
+ // This is intended for applications that wish to register specifically to this notification. Unlike ACTION_BATTERY_CHANGED,
+ // applications will be woken for this and so do not have to stay active to receive this notification. This action can be
+ // used to implement actions that wait until power is available to trigger.
+ //
+ // We use the same receiver for both the connected and disconnected intents.
+ _powerBroadcastReceiver = new AndroidPowerConnectionChangeBroadcastReceiver();
+ IntentFilter powerConnectFilter = new IntentFilter();
+ powerConnectFilter.AddAction(Intent.ActionPowerConnected);
+ powerConnectFilter.AddAction(Intent.ActionPowerDisconnected);
+ powerConnectFilter.AddCategory(Intent.CategoryDefault);
+ RegisterReceiver(_powerBroadcastReceiver, powerConnectFilter);
+
+ // must come after context initialization. also, it is here -- below StartForeground -- because it can
+ // take a while to complete and we don't want to run afoul of the short timing requirements on calling
+ // StartForeground.
+ SensusServiceHelper.Initialize(() => new AndroidSensusServiceHelper());
+
+ AndroidSensusServiceHelper serviceHelper = SensusServiceHelper.Get() as AndroidSensusServiceHelper;
+
+ // we might have failed to create the service helper. it's also happened that the service is created after the
+ // service helper is disposed: https://insights.xamarin.com/app/Sensus-Production/issues/46
+ if (serviceHelper == null)
+ {
+ Stop();
+ }
+ else
+ {
+ serviceHelper.SetService(this);
+ }
+ }
+
+ public override StartCommandResult OnStartCommand(Intent intent, StartCommandFlags flags, int startId)
+ {
+ AndroidSensusServiceHelper serviceHelper = SensusServiceHelper.Get() as AndroidSensusServiceHelper;
+
+ // there might be a race condition between the calling of this method and the stopping/disposal of the service helper.
+ // if the service helper is stopped/disposed before the service is stopped but after this method is called (e.g., by
+ // an alarm callback), the service helper will be null.
+ if (serviceHelper != null)
+ {
+ serviceHelper.Logger.Log("Sensus service received start command (startId=" + startId + ", flags=" + flags + ").", LoggingLevel.Normal, GetType());
+
+ // update the foreground service notification with information about loaded/running studies.
+ ReissueForegroundServiceNotification();
+
+ // if we started from the on-boot signal and there are no running protocols, stop the app now. there is no reason for
+ // the app to be running in this situation, and the user will likely be annoyed at the presence of the foreground
+ // service notification.
+ if (intent != null && intent.GetBooleanExtra(FROM_ON_BOOT_KEY, false) && serviceHelper.RunningProtocolIds.Count == 0)
+ {
+ serviceHelper.Logger.Log("Started from on-boot signal without running protocols. Stopping service now.", LoggingLevel.Normal, GetType());
+ Stop();
+ return StartCommandResult.NotSticky;
+ }
+
+ // acquire wake lock before this method returns to ensure that the device does not sleep prematurely, interrupting the execution of a callback.
+ serviceHelper.KeepDeviceAwake();
+
+ Task.Run(async () =>
+ {
+ // the service can be stopped without destroying the service object. in such cases,
+ // subsequent calls to start the service will not call OnCreate. therefore, it's
+ // important that any code called here is okay to call multiple times, even if the
+ // service is running. calling this when the service is running can happen because
+ // sensus receives a signal on device boot and for any callback alarms that are
+ // requested. furthermore, all calls here should be nonblocking / async so we don't
+ // tie up the UI thread.
+ await serviceHelper.StartAsync();
+
+ if (intent == null)
+ {
+ serviceHelper.LetDeviceSleep();
+ }
+ else
+ {
+ AndroidCallbackScheduler callbackScheduler = SensusContext.Current.CallbackScheduler as AndroidCallbackScheduler;
+
+ // is this a callback intent?
+ if (callbackScheduler.IsCallback(intent))
+ {
+ // service the callback -- the matching LetDeviceSleep will be called therein
+ await callbackScheduler.ServiceCallbackAsync(intent);
+ }
+ else
+ {
+ serviceHelper.LetDeviceSleep();
+ }
+ }
+ });
+ }
+
+ // if the service is killed by the system (e.g., due to resource constraints), ask the system to restart
+ // the service when possible.
+ return StartCommandResult.Sticky;
+ }
+
+ ///
+ /// Updates the foreground service notification builder, so that it reflects the enrollment status and participation level of the user.
+ ///
+ private void UpdateForegroundServiceNotificationBuilder()
+ {
+ AndroidSensusServiceHelper serviceHelper = SensusServiceHelper.Get() as AndroidSensusServiceHelper;
+
+ // the service helper will be null when this method is called from OnCreate. set some generic text until
+ // the service helper has a chance to load, at which time this method will be called again and we'll update
+ // the notification with more detailed information.
+ if (serviceHelper == null)
+ {
+ _foregroundServiceNotificationBuilder.SetContentTitle("Starting...");
+ _foregroundServiceNotificationBuilder.SetContentText("Tap to Open Sensus.");
+ }
+ // after the service helper has been initialized, we'll have more information about the studies.
+ else
+ {
+ int numRunningStudies = serviceHelper.RunningProtocolIds.Count;
+ _foregroundServiceNotificationBuilder.SetContentTitle("You are enrolled in " + numRunningStudies + " " + (numRunningStudies == 1 ? "study" : "studies") + ".");
+
+ string contentText = "";
+
+ // although the number of studies might be greater than 0, the protocols might not yet be started (e.g., after starting sensus).
+ List runningProtocols = serviceHelper.GetRunningProtocols();
+ if (runningProtocols.Count > 0)
+ {
+ double avgParticipation = runningProtocols.Average(protocol => protocol.Participation) * 100;
+ contentText += "Your overall participation level is " + Math.Round(avgParticipation, 0) + "%. ";
+ }
+
+ contentText += "Tap to open Sensus.";
+
+ _foregroundServiceNotificationBuilder.SetContentText(contentText);
+ }
+ }
+
+ public void ReissueForegroundServiceNotification()
+ {
+ UpdateForegroundServiceNotificationBuilder();
+ (GetSystemService(NotificationService) as NotificationManager).Notify(FOREGROUND_SERVICE_NOTIFICATION_ID, _foregroundServiceNotificationBuilder.Build());
+ }
+
+ public override IBinder OnBind(Intent intent)
+ {
+ AndroidSensusServiceBinder binder = new AndroidSensusServiceBinder(SensusServiceHelper.Get() as AndroidSensusServiceHelper);
+
+ lock (_bindings)
+ {
+ _bindings.Add(binder);
+ }
+
+ return binder;
+ }
+
+ public void Stop()
+ {
+ NotifyBindingsOfStop();
+ StopSelf();
+ }
+
+ private void NotifyBindingsOfStop()
+ {
+ // let everyone who is bound to the service know that we're going to stop.
+ lock (_bindings)
+ {
+ foreach (AndroidSensusServiceBinder binder in _bindings)
+ {
+ if (binder.SensusServiceHelper != null && binder.ServiceStopAction != null)
+ {
+ try
+ {
+ binder.ServiceStopAction();
+ }
+ catch (Exception)
+ {
+ }
+ }
+ }
+
+ _bindings.Clear();
+ }
+ }
+
+ public override async void OnDestroy()
+ {
+ Console.Error.WriteLine("--------------------------- Destroying Service ---------------------------");
+
+ AndroidSensusServiceHelper serviceHelper = SensusServiceHelper.Get() as AndroidSensusServiceHelper;
+
+ // the service helper will be null if we failed to create it within OnCreate, so first check that. also,
+ // OnDestroy can be called either when the user stops Sensus (in Android) and when the system reclaims
+ // the service under memory pressure. in the former case, we'll already have done the notification and
+ // stopping of protocols; however, we have no way to know how we reached OnDestroy, so to cover the latter
+ // case we're going to do the notification and stopping again. this will be duplicative in the case where
+ // the user has stopped sensus. in sum, anything we do below must be safe to run repeatedly.
+ if (serviceHelper != null)
+ {
+ serviceHelper.Logger.Log("Destroying service.", LoggingLevel.Normal, GetType());
+ NotifyBindingsOfStop();
+ await serviceHelper.StopProtocolsAsync();
+ serviceHelper.SetService(null);
+ }
+
+ // we've seen cases where the receiver doesn't get registered before the service is
+ // destroyed. catch exception raised from attempting to unregister a receiver that
+ // hasn't been registered.
+ try
+ {
+ UnregisterReceiver(_powerBroadcastReceiver);
+ }
+ catch (Exception)
+ { }
+
+ // do this last so that we don't dispose the service and its system services too early.
+ base.OnDestroy();
+ }
+ }
+}
diff --git a/Sensus.Android.Shared/AndroidSensusServiceBinder.cs b/Sensus.Android.Shared/AndroidSensusServiceBinder.cs
index b8c56c1a6..6960aef85 100644
--- a/Sensus.Android.Shared/AndroidSensusServiceBinder.cs
+++ b/Sensus.Android.Shared/AndroidSensusServiceBinder.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.OS;
using System;
diff --git a/Sensus.Android.Shared/AndroidSensusServiceBootStarter.cs b/Sensus.Android.Shared/AndroidSensusServiceBootStarter.cs
index d1bf4745c..dab4eaeee 100644
--- a/Sensus.Android.Shared/AndroidSensusServiceBootStarter.cs
+++ b/Sensus.Android.Shared/AndroidSensusServiceBootStarter.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Android.App;
@@ -39,4 +44,4 @@ public override void OnReceive(global::Android.Content.Context context, Intent i
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/AndroidSensusServiceConnection.cs b/Sensus.Android.Shared/AndroidSensusServiceConnection.cs
index d39a64e72..10dc21a47 100644
--- a/Sensus.Android.Shared/AndroidSensusServiceConnection.cs
+++ b/Sensus.Android.Shared/AndroidSensusServiceConnection.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Content;
using Android.OS;
diff --git a/Sensus.Android.Shared/AndroidSensusServiceHelper.cs b/Sensus.Android.Shared/AndroidSensusServiceHelper.cs
index 00f2fc454..1a5f4bbd5 100644
--- a/Sensus.Android.Shared/AndroidSensusServiceHelper.cs
+++ b/Sensus.Android.Shared/AndroidSensusServiceHelper.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
@@ -800,4 +805,4 @@ public SensorManager GetSensorManager()
return _service.GetSystemService(global::Android.Content.Context.SensorService) as SensorManager;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/AndroidServiceConnectedEventArgs.cs b/Sensus.Android.Shared/AndroidServiceConnectedEventArgs.cs
index 4078a4c38..578c5d7ab 100644
--- a/Sensus.Android.Shared/AndroidServiceConnectedEventArgs.cs
+++ b/Sensus.Android.Shared/AndroidServiceConnectedEventArgs.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Android
{
diff --git a/Sensus.Android.Shared/AndroidTextToSpeech.cs b/Sensus.Android.Shared/AndroidTextToSpeech.cs
index 70bdbf2cc..77fa4b819 100644
--- a/Sensus.Android.Shared/AndroidTextToSpeech.cs
+++ b/Sensus.Android.Shared/AndroidTextToSpeech.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Speech.Tts;
using System;
diff --git a/Sensus.Android.Shared/Callbacks/AndroidCallbackScheduler.cs b/Sensus.Android.Shared/Callbacks/AndroidCallbackScheduler.cs
index d0786130a..5126594e5 100644
--- a/Sensus.Android.Shared/Callbacks/AndroidCallbackScheduler.cs
+++ b/Sensus.Android.Shared/Callbacks/AndroidCallbackScheduler.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.App;
using Android.Content;
@@ -205,4 +210,4 @@ protected override void UnscheduleCallbackPlatformSpecific(ScheduledCallback cal
SensusServiceHelper.Get().Logger.Log("Unscheduled alarm for callback " + callback.Id + ".", LoggingLevel.Normal, GetType());
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Concurrent/MainConcurrent.cs b/Sensus.Android.Shared/Concurrent/MainConcurrent.cs
index 1900d8e6d..6e80f5a56 100644
--- a/Sensus.Android.Shared/Concurrent/MainConcurrent.cs
+++ b/Sensus.Android.Shared/Concurrent/MainConcurrent.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
@@ -144,4 +149,4 @@ protected override void Dispose(bool disposing)
base.Dispose(disposing);
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Context/AndroidSensusContext.cs b/Sensus.Android.Shared/Context/AndroidSensusContext.cs
index f93482fdf..4948e26bb 100644
--- a/Sensus.Android.Shared/Context/AndroidSensusContext.cs
+++ b/Sensus.Android.Shared/Context/AndroidSensusContext.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus.Encryption;
using Sensus.Concurrent;
@@ -33,4 +38,4 @@ public class AndroidSensusContext : ISensusContext
public string IamAccessKeySecret { get; set; }
public PowerConnectionChangeListener PowerConnectionChangeListener { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Notifications/AndroidNotifier.cs b/Sensus.Android.Shared/Notifications/AndroidNotifier.cs
index 655d3920c..f7b751f41 100644
--- a/Sensus.Android.Shared/Notifications/AndroidNotifier.cs
+++ b/Sensus.Android.Shared/Notifications/AndroidNotifier.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading.Tasks;
@@ -248,4 +253,4 @@ public override void CancelNotification(string id)
_notificationManager.Cancel(id, 0);
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Notifications/FirebaseNotificationService.cs b/Sensus.Android.Shared/Notifications/FirebaseNotificationService.cs
index 865aa92ba..cf2487abc 100644
--- a/Sensus.Android.Shared/Notifications/FirebaseNotificationService.cs
+++ b/Sensus.Android.Shared/Notifications/FirebaseNotificationService.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Android.App;
@@ -47,4 +52,4 @@ public async override void OnMessageReceived(RemoteMessage message)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Notifications/FirebaseRegistrationService.cs b/Sensus.Android.Shared/Notifications/FirebaseRegistrationService.cs
index cd4621eca..852cd95f3 100644
--- a/Sensus.Android.Shared/Notifications/FirebaseRegistrationService.cs
+++ b/Sensus.Android.Shared/Notifications/FirebaseRegistrationService.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.App;
using Firebase.Iid;
@@ -30,4 +35,4 @@ public override async void OnTokenRefresh()
await SensusServiceHelper.Get()?.UpdatePushNotificationRegistrationsAsync(default(CancellationToken));
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/AndroidSensorListener.cs b/Sensus.Android.Shared/Probes/AndroidSensorListener.cs
index 8359c6328..a174e5703 100644
--- a/Sensus.Android.Shared/Probes/AndroidSensorListener.cs
+++ b/Sensus.Android.Shared/Probes/AndroidSensorListener.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus;
using System;
@@ -124,4 +129,4 @@ public void OnAccuracyChanged(Sensor sensor, SensorStatus accuracy)
{
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Apps/AndroidFacebookProbe.cs b/Sensus.Android.Shared/Probes/Apps/AndroidFacebookProbe.cs
index 36943f768..c94a26866 100644
--- a/Sensus.Android.Shared/Probes/Apps/AndroidFacebookProbe.cs
+++ b/Sensus.Android.Shared/Probes/Apps/AndroidFacebookProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
@@ -307,4 +312,4 @@ protected override ICollection GetGrantedPermissions()
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Communication/AndroidSmsIncomingBroadcastReceiver.cs b/Sensus.Android.Shared/Probes/Communication/AndroidSmsIncomingBroadcastReceiver.cs
index 615ba7420..18abf3493 100644
--- a/Sensus.Android.Shared/Probes/Communication/AndroidSmsIncomingBroadcastReceiver.cs
+++ b/Sensus.Android.Shared/Probes/Communication/AndroidSmsIncomingBroadcastReceiver.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.App;
using Android.Content;
@@ -76,4 +81,4 @@ public override void OnReceive(global::Android.Content.Context context, Intent i
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Communication/AndroidSmsOutgoingObserver.cs b/Sensus.Android.Shared/Probes/Communication/AndroidSmsOutgoingObserver.cs
index 8515f533c..6df3a065f 100644
--- a/Sensus.Android.Shared/Probes/Communication/AndroidSmsOutgoingObserver.cs
+++ b/Sensus.Android.Shared/Probes/Communication/AndroidSmsOutgoingObserver.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.App;
using Android.Database;
@@ -315,4 +320,4 @@ private string GetAddressNumber(int id, int type)
return number;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Communication/AndroidSmsProbe.cs b/Sensus.Android.Shared/Probes/Communication/AndroidSmsProbe.cs
index bfa2361a0..491af5430 100644
--- a/Sensus.Android.Shared/Probes/Communication/AndroidSmsProbe.cs
+++ b/Sensus.Android.Shared/Probes/Communication/AndroidSmsProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Android.App;
@@ -88,4 +93,4 @@ protected override Task StopListeningAsync()
return Task.CompletedTask;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyIdleIncomingListener.cs b/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyIdleIncomingListener.cs
index 438cd840b..927ee1365 100644
--- a/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyIdleIncomingListener.cs
+++ b/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyIdleIncomingListener.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Telephony;
using System;
@@ -41,4 +46,4 @@ public override void OnCallStateChanged(CallState state, string phoneNumber)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyOutgoingBroadcastReceiver.cs b/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyOutgoingBroadcastReceiver.cs
index 6ca6b0ed2..8c43d432c 100644
--- a/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyOutgoingBroadcastReceiver.cs
+++ b/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyOutgoingBroadcastReceiver.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.App;
using Android.Content;
diff --git a/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyProbe.cs b/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyProbe.cs
index ccda3e633..d41f9fa31 100644
--- a/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyProbe.cs
+++ b/Sensus.Android.Shared/Probes/Communication/AndroidTelephonyProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.App;
using Android.Telephony;
diff --git a/Sensus.Android.Shared/Probes/Context/AndroidAmbientTemperatureProbe.cs b/Sensus.Android.Shared/Probes/Context/AndroidAmbientTemperatureProbe.cs
index a66ea5e55..dba5adb99 100644
--- a/Sensus.Android.Shared/Probes/Context/AndroidAmbientTemperatureProbe.cs
+++ b/Sensus.Android.Shared/Probes/Context/AndroidAmbientTemperatureProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Android.Hardware;
@@ -58,4 +63,4 @@ protected override Task StopListeningAsync()
return Task.CompletedTask;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Context/AndroidBluetoothBroadcastReceiver.cs b/Sensus.Android.Shared/Probes/Context/AndroidBluetoothBroadcastReceiver.cs
index 43473fd1a..29f82b887 100644
--- a/Sensus.Android.Shared/Probes/Context/AndroidBluetoothBroadcastReceiver.cs
+++ b/Sensus.Android.Shared/Probes/Context/AndroidBluetoothBroadcastReceiver.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.App;
using Android.Bluetooth;
@@ -61,4 +66,4 @@ public override void OnReceive(global::Android.Content.Context context, Intent i
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Context/AndroidBluetoothClientGattCallback.cs b/Sensus.Android.Shared/Probes/Context/AndroidBluetoothClientGattCallback.cs
index 831db0513..8d73d23be 100644
--- a/Sensus.Android.Shared/Probes/Context/AndroidBluetoothClientGattCallback.cs
+++ b/Sensus.Android.Shared/Probes/Context/AndroidBluetoothClientGattCallback.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Android.Bluetooth;
diff --git a/Sensus.Android.Shared/Probes/Context/AndroidBluetoothClientScannerCallback.cs b/Sensus.Android.Shared/Probes/Context/AndroidBluetoothClientScannerCallback.cs
index b73e88b68..d432ff978 100644
--- a/Sensus.Android.Shared/Probes/Context/AndroidBluetoothClientScannerCallback.cs
+++ b/Sensus.Android.Shared/Probes/Context/AndroidBluetoothClientScannerCallback.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
@@ -84,4 +89,4 @@ private void ProcessScanResult(ScanResult result)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Context/AndroidBluetoothDeviceProximityProbe.cs b/Sensus.Android.Shared/Probes/Context/AndroidBluetoothDeviceProximityProbe.cs
index 3098ea727..6891980bb 100644
--- a/Sensus.Android.Shared/Probes/Context/AndroidBluetoothDeviceProximityProbe.cs
+++ b/Sensus.Android.Shared/Probes/Context/AndroidBluetoothDeviceProximityProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Probes.Context;
@@ -225,4 +230,4 @@ public override async Task TestHealthAsync(List
- /// Android BLE server advertising callback. Receives events related to the starting and
- /// stopping of BLE advertising. Configures a BLE server that responds to client read requests.
- ///
- public class AndroidBluetoothServerAdvertisingCallback : AdvertiseCallback
- {
- private BluetoothGattService _service;
- private BluetoothGattCharacteristic _characteristic;
- private BluetoothGattServer _gattServer;
-
- public AndroidBluetoothServerAdvertisingCallback(BluetoothGattService service, BluetoothGattCharacteristic characteristic)
- {
- _service = service;
- _characteristic = characteristic;
- }
-
- ///
- /// Called when advertising has successfully started. Sets up a BLE server to handle client requests.
- ///
- /// Settings in effect.
- public override void OnStartSuccess(AdvertiseSettings settingsInEffect)
- {
- SensusServiceHelper.Get().Logger.Log("Started advertising.", LoggingLevel.Normal, GetType());
-
- SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
- {
- // the following should never happen, but just in case there is an existing server, close it.
- if (_gattServer != null)
- {
- CloseServer();
- }
-
- try
- {
- // create a callback to receive read requests events from client
- AndroidBluetoothServerGattCallback serverCallback = new AndroidBluetoothServerGattCallback(_service, _characteristic);
-
- // open the server, which contains the substantive connection with a client. this also registers the callback.
- BluetoothManager bluetoothManager = Application.Context.GetSystemService(global::Android.Content.Context.BluetoothService) as BluetoothManager;
- _gattServer = bluetoothManager.OpenGattServer(Application.Context, serverCallback);
-
- // set the server on callback, so that responses to read requests can be sent back to clients.
- serverCallback.Server = _gattServer;
-
- // declare the BLE service handled by the server, which is the same as the one advertised.
- _gattServer.AddService(_service);
- }
- catch (Exception ex)
- {
- SensusServiceHelper.Get().Logger.Log("Exception while starting server: " + ex, LoggingLevel.Normal, GetType());
- CloseServer();
- }
- });
- }
-
- public override void OnStartFailure(AdvertiseFailure errorCode)
- {
- SensusServiceHelper.Get().Logger.Log("Failed to start advertising:" + errorCode, LoggingLevel.Normal, GetType());
- }
-
- public void CloseServer()
- {
- SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
- {
- // remove the service
- try
- {
- _gattServer?.RemoveService(_service);
- }
- catch (Exception ex)
- {
- SensusServiceHelper.Get().Logger.Log("Exception while removing service: " + ex.Message, LoggingLevel.Normal, GetType());
- }
-
- // close the server
- try
- {
- _gattServer?.Close();
- }
- catch (Exception ex)
- {
- SensusServiceHelper.Get().Logger.Log("Exception while closing GATT server: " + ex.Message, LoggingLevel.Normal, GetType());
- }
- finally
- {
- _gattServer = null;
- }
- });
- }
- }
-}
\ No newline at end of file
+using Android.Bluetooth.LE;
+using Sensus.Context;
+
+namespace Sensus.Android.Probes.Context
+{
+ ///
+ /// Android BLE server advertising callback. Receives events related to the starting and
+ /// stopping of BLE advertising. Configures a BLE server that responds to client read requests.
+ ///
+ public class AndroidBluetoothServerAdvertisingCallback : AdvertiseCallback
+ {
+ private BluetoothGattService _service;
+ private BluetoothGattCharacteristic _characteristic;
+ private BluetoothGattServer _gattServer;
+
+ public AndroidBluetoothServerAdvertisingCallback(BluetoothGattService service, BluetoothGattCharacteristic characteristic)
+ {
+ _service = service;
+ _characteristic = characteristic;
+ }
+
+ ///
+ /// Called when advertising has successfully started. Sets up a BLE server to handle client requests.
+ ///
+ /// Settings in effect.
+ public override void OnStartSuccess(AdvertiseSettings settingsInEffect)
+ {
+ SensusServiceHelper.Get().Logger.Log("Started advertising.", LoggingLevel.Normal, GetType());
+
+ SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
+ {
+ // the following should never happen, but just in case there is an existing server, close it.
+ if (_gattServer != null)
+ {
+ CloseServer();
+ }
+
+ try
+ {
+ // create a callback to receive read requests events from client
+ AndroidBluetoothServerGattCallback serverCallback = new AndroidBluetoothServerGattCallback(_service, _characteristic);
+
+ // open the server, which contains the substantive connection with a client. this also registers the callback.
+ BluetoothManager bluetoothManager = Application.Context.GetSystemService(global::Android.Content.Context.BluetoothService) as BluetoothManager;
+ _gattServer = bluetoothManager.OpenGattServer(Application.Context, serverCallback);
+
+ // set the server on callback, so that responses to read requests can be sent back to clients.
+ serverCallback.Server = _gattServer;
+
+ // declare the BLE service handled by the server, which is the same as the one advertised.
+ _gattServer.AddService(_service);
+ }
+ catch (Exception ex)
+ {
+ SensusServiceHelper.Get().Logger.Log("Exception while starting server: " + ex, LoggingLevel.Normal, GetType());
+ CloseServer();
+ }
+ });
+ }
+
+ public override void OnStartFailure(AdvertiseFailure errorCode)
+ {
+ SensusServiceHelper.Get().Logger.Log("Failed to start advertising:" + errorCode, LoggingLevel.Normal, GetType());
+ }
+
+ public void CloseServer()
+ {
+ SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
+ {
+ // remove the service
+ try
+ {
+ _gattServer?.RemoveService(_service);
+ }
+ catch (Exception ex)
+ {
+ SensusServiceHelper.Get().Logger.Log("Exception while removing service: " + ex.Message, LoggingLevel.Normal, GetType());
+ }
+
+ // close the server
+ try
+ {
+ _gattServer?.Close();
+ }
+ catch (Exception ex)
+ {
+ SensusServiceHelper.Get().Logger.Log("Exception while closing GATT server: " + ex.Message, LoggingLevel.Normal, GetType());
+ }
+ finally
+ {
+ _gattServer = null;
+ }
+ });
+ }
+ }
+}
diff --git a/Sensus.Android.Shared/Probes/Context/AndroidBluetoothServerGattCallback.cs b/Sensus.Android.Shared/Probes/Context/AndroidBluetoothServerGattCallback.cs
index 735cf70df..ca3cf66ad 100644
--- a/Sensus.Android.Shared/Probes/Context/AndroidBluetoothServerGattCallback.cs
+++ b/Sensus.Android.Shared/Probes/Context/AndroidBluetoothServerGattCallback.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Android.Bluetooth;
diff --git a/Sensus.Android.Shared/Probes/Context/AndroidHumidityProbe.cs b/Sensus.Android.Shared/Probes/Context/AndroidHumidityProbe.cs
index 75102637d..386badcde 100644
--- a/Sensus.Android.Shared/Probes/Context/AndroidHumidityProbe.cs
+++ b/Sensus.Android.Shared/Probes/Context/AndroidHumidityProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Android.Hardware;
@@ -58,4 +63,4 @@ protected override Task StopListeningAsync()
return Task.CompletedTask;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Context/AndroidLightProbe.cs b/Sensus.Android.Shared/Probes/Context/AndroidLightProbe.cs
index 72aa5725d..73a1c4835 100644
--- a/Sensus.Android.Shared/Probes/Context/AndroidLightProbe.cs
+++ b/Sensus.Android.Shared/Probes/Context/AndroidLightProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Hardware;
using Sensus.Probes.Context;
diff --git a/Sensus.Android.Shared/Probes/Context/AndroidSoundProbe.cs b/Sensus.Android.Shared/Probes/Context/AndroidSoundProbe.cs
index 8983c97b5..ae989bf22 100644
--- a/Sensus.Android.Shared/Probes/Context/AndroidSoundProbe.cs
+++ b/Sensus.Android.Shared/Probes/Context/AndroidSoundProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
diff --git a/Sensus.Android.Shared/Probes/Device/AndroidScreenProbe.cs b/Sensus.Android.Shared/Probes/Device/AndroidScreenProbe.cs
index c7e7b6791..f8d29d10e 100644
--- a/Sensus.Android.Shared/Probes/Device/AndroidScreenProbe.cs
+++ b/Sensus.Android.Shared/Probes/Device/AndroidScreenProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
diff --git a/Sensus.Android.Shared/Probes/Location/AndroidAltitudeProbe.cs b/Sensus.Android.Shared/Probes/Location/AndroidAltitudeProbe.cs
index b55fc017c..393d6889d 100644
--- a/Sensus.Android.Shared/Probes/Location/AndroidAltitudeProbe.cs
+++ b/Sensus.Android.Shared/Probes/Location/AndroidAltitudeProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Hardware;
using Sensus.Probes.Location;
diff --git a/Sensus.Android.Shared/Probes/Location/AndroidCompassProbe.cs b/Sensus.Android.Shared/Probes/Location/AndroidCompassProbe.cs
index dbd3617f6..4df06b343 100644
--- a/Sensus.Android.Shared/Probes/Location/AndroidCompassProbe.cs
+++ b/Sensus.Android.Shared/Probes/Location/AndroidCompassProbe.cs
@@ -1,137 +1,142 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System;
using System.Linq;
-using System.Threading.Tasks;
-using Android.Hardware;
-using Sensus;
-using Sensus.Probes.Location;
-using Syncfusion.SfChart.XForms;
-
-namespace Sensus.Android.Probes.Location
-{
- public class AndroidCompassProbe : CompassProbe
- {
- private AndroidSensorListener _magnetometerListener;
- private float[] _magneticFieldValues;
-
- private AndroidSensorListener _accelerometerListener;
- private float[] _accelerometerValues;
-
- public AndroidCompassProbe()
- {
- _magneticFieldValues = new float[3];
- _magnetometerListener = new AndroidSensorListener(SensorType.MagneticField, async e =>
- {
- if (e.Values != null && e.Values.Count == 3)
- {
- await StoreHeadingAsync(magneticFieldValues: e.Values.ToArray());
- }
- });
-
- _accelerometerValues = new float[3];
- _accelerometerListener = new AndroidSensorListener(SensorType.Accelerometer, async e =>
- {
- if (e.Values != null && e.Values.Count == 3)
- {
- await StoreHeadingAsync(accelerometerValues: e.Values.ToArray());
- }
- });
- }
-
- protected override async Task InitializeAsync()
- {
- await base.InitializeAsync();
-
- _magnetometerListener.Initialize(MinDataStoreDelay);
- _accelerometerListener.Initialize(MinDataStoreDelay);
- }
-
- protected override Task StartListeningAsync()
- {
- _magnetometerListener.Start();
- _accelerometerListener.Start();
- return Task.CompletedTask;
- }
-
- private async Task StoreHeadingAsync(float[] magneticFieldValues = null, float[] accelerometerValues = null)
- {
- float[] rotationMatrix = new float[9];
-
- // if either the accelerometer or magnetic field values are missing, use the old ones
- if (SensorManager.GetRotationMatrix(rotationMatrix, null, accelerometerValues ?? _accelerometerValues, magneticFieldValues ?? _magneticFieldValues))
- {
- float[] azimuthPitchRoll = new float[3];
-
- SensorManager.GetOrientation(rotationMatrix, azimuthPitchRoll);
-
- double heading = azimuthPitchRoll[0] * (180 / Math.PI); // convert heading radians to heading degrees
-
- if (heading < 0)
- {
- heading = 180 + (180 - Math.Abs(heading)); // convert to [0, 360] degrees from north
- }
-
- // looks like it's very risky to use e.Timestamp as the basis for timestamping our Datum objects. depending on the phone
- // manufacturer and android version, e.Timestamp will be set relative to different anchors. this makes it impossible to
- // compare data across sensors, phones, and android versions. using DateTimeOffset.UtcNow will cause imprecision due to
- // latencies between reading time and execution time of the following line of code; however, these will be small under
- // most conditions. one exception is when the listening probe lets the device sleep. in this case readings will be paused
- // until the cpu wakes up, at which time any cached readings will be delivered in bulk to sensus. each of these readings
- // will be timestamped with similar times by the following line of code, when in reality they originated much earlier. this
- // will only happen when all listening probes are configured to allow the device to sleep.
- await StoreDatumAsync(new CompassDatum(DateTimeOffset.UtcNow, heading));
- }
-
- // update values for next call
- if (magneticFieldValues != null)
- {
- _magneticFieldValues = magneticFieldValues;
- }
-
- if (accelerometerValues != null)
- {
- _accelerometerValues = accelerometerValues;
- }
- }
-
- protected override Task StopListeningAsync()
- {
- _magnetometerListener.Stop();
- _accelerometerListener.Stop();
- return Task.CompletedTask;
- }
-
- protected override ChartSeries GetChartSeries()
- {
- throw new NotImplementedException();
- }
-
- protected override ChartDataPoint GetChartDataPointFromDatum(Datum datum)
- {
- throw new NotImplementedException();
- }
-
- protected override ChartAxis GetChartPrimaryAxis()
- {
- throw new NotImplementedException();
- }
-
- protected override RangeAxisBase GetChartSecondaryAxis()
- {
- throw new NotImplementedException();
- }
- }
-}
\ No newline at end of file
+using System.Threading.Tasks;
+using Android.Hardware;
+using Sensus;
+using Sensus.Probes.Location;
+using Syncfusion.SfChart.XForms;
+
+namespace Sensus.Android.Probes.Location
+{
+ public class AndroidCompassProbe : CompassProbe
+ {
+ private AndroidSensorListener _magnetometerListener;
+ private float[] _magneticFieldValues;
+
+ private AndroidSensorListener _accelerometerListener;
+ private float[] _accelerometerValues;
+
+ public AndroidCompassProbe()
+ {
+ _magneticFieldValues = new float[3];
+ _magnetometerListener = new AndroidSensorListener(SensorType.MagneticField, async e =>
+ {
+ if (e.Values != null && e.Values.Count == 3)
+ {
+ await StoreHeadingAsync(magneticFieldValues: e.Values.ToArray());
+ }
+ });
+
+ _accelerometerValues = new float[3];
+ _accelerometerListener = new AndroidSensorListener(SensorType.Accelerometer, async e =>
+ {
+ if (e.Values != null && e.Values.Count == 3)
+ {
+ await StoreHeadingAsync(accelerometerValues: e.Values.ToArray());
+ }
+ });
+ }
+
+ protected override async Task InitializeAsync()
+ {
+ await base.InitializeAsync();
+
+ _magnetometerListener.Initialize(MinDataStoreDelay);
+ _accelerometerListener.Initialize(MinDataStoreDelay);
+ }
+
+ protected override Task StartListeningAsync()
+ {
+ _magnetometerListener.Start();
+ _accelerometerListener.Start();
+ return Task.CompletedTask;
+ }
+
+ private async Task StoreHeadingAsync(float[] magneticFieldValues = null, float[] accelerometerValues = null)
+ {
+ float[] rotationMatrix = new float[9];
+
+ // if either the accelerometer or magnetic field values are missing, use the old ones
+ if (SensorManager.GetRotationMatrix(rotationMatrix, null, accelerometerValues ?? _accelerometerValues, magneticFieldValues ?? _magneticFieldValues))
+ {
+ float[] azimuthPitchRoll = new float[3];
+
+ SensorManager.GetOrientation(rotationMatrix, azimuthPitchRoll);
+
+ double heading = azimuthPitchRoll[0] * (180 / Math.PI); // convert heading radians to heading degrees
+
+ if (heading < 0)
+ {
+ heading = 180 + (180 - Math.Abs(heading)); // convert to [0, 360] degrees from north
+ }
+
+ // looks like it's very risky to use e.Timestamp as the basis for timestamping our Datum objects. depending on the phone
+ // manufacturer and android version, e.Timestamp will be set relative to different anchors. this makes it impossible to
+ // compare data across sensors, phones, and android versions. using DateTimeOffset.UtcNow will cause imprecision due to
+ // latencies between reading time and execution time of the following line of code; however, these will be small under
+ // most conditions. one exception is when the listening probe lets the device sleep. in this case readings will be paused
+ // until the cpu wakes up, at which time any cached readings will be delivered in bulk to sensus. each of these readings
+ // will be timestamped with similar times by the following line of code, when in reality they originated much earlier. this
+ // will only happen when all listening probes are configured to allow the device to sleep.
+ await StoreDatumAsync(new CompassDatum(DateTimeOffset.UtcNow, heading));
+ }
+
+ // update values for next call
+ if (magneticFieldValues != null)
+ {
+ _magneticFieldValues = magneticFieldValues;
+ }
+
+ if (accelerometerValues != null)
+ {
+ _accelerometerValues = accelerometerValues;
+ }
+ }
+
+ protected override Task StopListeningAsync()
+ {
+ _magnetometerListener.Stop();
+ _accelerometerListener.Stop();
+ return Task.CompletedTask;
+ }
+
+ protected override ChartSeries GetChartSeries()
+ {
+ throw new NotImplementedException();
+ }
+
+ protected override ChartDataPoint GetChartDataPointFromDatum(Datum datum)
+ {
+ throw new NotImplementedException();
+ }
+
+ protected override ChartAxis GetChartPrimaryAxis()
+ {
+ throw new NotImplementedException();
+ }
+
+ protected override RangeAxisBase GetChartSecondaryAxis()
+ {
+ throw new NotImplementedException();
+ }
+ }
+}
diff --git a/Sensus.Android.Shared/Probes/Location/AndroidEstimoteBeaconProbe.cs b/Sensus.Android.Shared/Probes/Location/AndroidEstimoteBeaconProbe.cs
index bc3a23a42..7b29bd912 100644
--- a/Sensus.Android.Shared/Probes/Location/AndroidEstimoteBeaconProbe.cs
+++ b/Sensus.Android.Shared/Probes/Location/AndroidEstimoteBeaconProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Estimote.Android.Proximity;
@@ -113,4 +118,4 @@ protected override Task StopListeningAsync()
return Task.CompletedTask;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Location/AndroidProximityProbe.cs b/Sensus.Android.Shared/Probes/Location/AndroidProximityProbe.cs
index 5e197bbd6..a58b3e7ac 100644
--- a/Sensus.Android.Shared/Probes/Location/AndroidProximityProbe.cs
+++ b/Sensus.Android.Shared/Probes/Location/AndroidProximityProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Hardware;
using Sensus.Probes.Location;
@@ -76,4 +81,4 @@ protected override Task StopListeningAsync()
return Task.CompletedTask;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Movement/AndroidAccelerometerProbe.cs b/Sensus.Android.Shared/Probes/Movement/AndroidAccelerometerProbe.cs
index 637be8fd2..987937449 100644
--- a/Sensus.Android.Shared/Probes/Movement/AndroidAccelerometerProbe.cs
+++ b/Sensus.Android.Shared/Probes/Movement/AndroidAccelerometerProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Hardware;
using Sensus.Probes.Movement;
@@ -66,4 +71,4 @@ protected override Task StopListeningAsync()
return Task.CompletedTask;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Movement/AndroidActivityProbe.cs b/Sensus.Android.Shared/Probes/Movement/AndroidActivityProbe.cs
index 2d82d3a8f..d8001fe2c 100644
--- a/Sensus.Android.Shared/Probes/Movement/AndroidActivityProbe.cs
+++ b/Sensus.Android.Shared/Probes/Movement/AndroidActivityProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Android.Gms.Awareness.Fence;
@@ -142,4 +147,4 @@ private async Task RemovePhasedFencesAsync(int activityId, string activityName)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Movement/AndroidAwarenessProbe.cs b/Sensus.Android.Shared/Probes/Movement/AndroidAwarenessProbe.cs
index 2031b638d..d5c3e458d 100644
--- a/Sensus.Android.Shared/Probes/Movement/AndroidAwarenessProbe.cs
+++ b/Sensus.Android.Shared/Probes/Movement/AndroidAwarenessProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
diff --git a/Sensus.Android.Shared/Probes/Movement/AndroidAwarenessProbeBroadcastReceiver.cs b/Sensus.Android.Shared/Probes/Movement/AndroidAwarenessProbeBroadcastReceiver.cs
index e1c91f3a3..eaad9e78f 100644
--- a/Sensus.Android.Shared/Probes/Movement/AndroidAwarenessProbeBroadcastReceiver.cs
+++ b/Sensus.Android.Shared/Probes/Movement/AndroidAwarenessProbeBroadcastReceiver.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Android.Content;
@@ -106,4 +111,4 @@ public override void OnReceive(global::Android.Content.Context context, Intent i
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Movement/AndroidGyroscopeProbe.cs b/Sensus.Android.Shared/Probes/Movement/AndroidGyroscopeProbe.cs
index a8ad1bebb..82fca76e0 100644
--- a/Sensus.Android.Shared/Probes/Movement/AndroidGyroscopeProbe.cs
+++ b/Sensus.Android.Shared/Probes/Movement/AndroidGyroscopeProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Hardware;
using Sensus.Exceptions;
@@ -57,4 +62,4 @@ protected override Task StopListeningAsync()
return Task.CompletedTask;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Movement/AndroidLocationFenceProbe.cs b/Sensus.Android.Shared/Probes/Movement/AndroidLocationFenceProbe.cs
index f93999b3e..83a1c07fe 100644
--- a/Sensus.Android.Shared/Probes/Movement/AndroidLocationFenceProbe.cs
+++ b/Sensus.Android.Shared/Probes/Movement/AndroidLocationFenceProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
diff --git a/Sensus.Android.Shared/Probes/Network/AndroidCellTowerChangeListener.cs b/Sensus.Android.Shared/Probes/Network/AndroidCellTowerChangeListener.cs
index 7e83f78d4..3880d34d9 100644
--- a/Sensus.Android.Shared/Probes/Network/AndroidCellTowerChangeListener.cs
+++ b/Sensus.Android.Shared/Probes/Network/AndroidCellTowerChangeListener.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Telephony;
using System;
@@ -52,4 +57,4 @@ public override void OnCellLocationChanged(CellLocation location)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/Probes/Network/AndroidCellTowerProbe.cs b/Sensus.Android.Shared/Probes/Network/AndroidCellTowerProbe.cs
index ee6b407fe..b61f16f88 100644
--- a/Sensus.Android.Shared/Probes/Network/AndroidCellTowerProbe.cs
+++ b/Sensus.Android.Shared/Probes/Network/AndroidCellTowerProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.App;
using Android.Telephony;
diff --git a/Sensus.Android.Shared/Probes/Network/AndroidListeningWlanProbe.cs b/Sensus.Android.Shared/Probes/Network/AndroidListeningWlanProbe.cs
index f9a8fa63e..e04255805 100644
--- a/Sensus.Android.Shared/Probes/Network/AndroidListeningWlanProbe.cs
+++ b/Sensus.Android.Shared/Probes/Network/AndroidListeningWlanProbe.cs
@@ -1,61 +1,66 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
using Android.App;
-using Android.Content;
-using Android.Net;
-using Sensus.Probes.Network;
-using System;
-using System.Threading.Tasks;
-
-namespace Sensus.Android.Probes.Network
-{
- public class AndroidListeningWlanProbe : ListeningWlanProbe
- {
- private AndroidWlanBroadcastReceiver _wlanBroadcastReceiver;
- private EventHandler _wlanConnectionChangedCallback;
-
- public AndroidListeningWlanProbe()
- {
- _wlanBroadcastReceiver = new AndroidWlanBroadcastReceiver();
-
- _wlanConnectionChangedCallback = async (sender, wlanDatum) =>
- {
- await StoreDatumAsync(wlanDatum);
- };
- }
-
- protected override Task StartListeningAsync()
- {
- // register receiver for all WLAN intent actions
-#pragma warning disable CS0618 // Type or member is obsolete
- Application.Context.RegisterReceiver(_wlanBroadcastReceiver, new IntentFilter(ConnectivityManager.ConnectivityAction));
-#pragma warning restore CS0618 // Type or member is obsolete
-
- AndroidWlanBroadcastReceiver.WIFI_CONNECTION_CHANGED += _wlanConnectionChangedCallback;
-
- return Task.CompletedTask;
- }
-
- protected override Task StopListeningAsync()
- {
- // stop broadcast receiver
- Application.Context.UnregisterReceiver(_wlanBroadcastReceiver);
-
- AndroidWlanBroadcastReceiver.WIFI_CONNECTION_CHANGED -= _wlanConnectionChangedCallback;
-
- return Task.CompletedTask;
- }
- }
-}
\ No newline at end of file
+using Android.Content;
+using Android.Net;
+using Sensus.Probes.Network;
+using System;
+using System.Threading.Tasks;
+
+namespace Sensus.Android.Probes.Network
+{
+ public class AndroidListeningWlanProbe : ListeningWlanProbe
+ {
+ private AndroidWlanBroadcastReceiver _wlanBroadcastReceiver;
+ private EventHandler _wlanConnectionChangedCallback;
+
+ public AndroidListeningWlanProbe()
+ {
+ _wlanBroadcastReceiver = new AndroidWlanBroadcastReceiver();
+
+ _wlanConnectionChangedCallback = async (sender, wlanDatum) =>
+ {
+ await StoreDatumAsync(wlanDatum);
+ };
+ }
+
+ protected override Task StartListeningAsync()
+ {
+ // register receiver for all WLAN intent actions
+#pragma warning disable CS0618 // Type or member is obsolete
+ Application.Context.RegisterReceiver(_wlanBroadcastReceiver, new IntentFilter(ConnectivityManager.ConnectivityAction));
+#pragma warning restore CS0618 // Type or member is obsolete
+
+ AndroidWlanBroadcastReceiver.WIFI_CONNECTION_CHANGED += _wlanConnectionChangedCallback;
+
+ return Task.CompletedTask;
+ }
+
+ protected override Task StopListeningAsync()
+ {
+ // stop broadcast receiver
+ Application.Context.UnregisterReceiver(_wlanBroadcastReceiver);
+
+ AndroidWlanBroadcastReceiver.WIFI_CONNECTION_CHANGED -= _wlanConnectionChangedCallback;
+
+ return Task.CompletedTask;
+ }
+ }
+}
diff --git a/Sensus.Android.Shared/Probes/Network/AndroidWlanBroadcastReceiver.cs b/Sensus.Android.Shared/Probes/Network/AndroidWlanBroadcastReceiver.cs
index 6f3d45503..bbdb91ff4 100644
--- a/Sensus.Android.Shared/Probes/Network/AndroidWlanBroadcastReceiver.cs
+++ b/Sensus.Android.Shared/Probes/Network/AndroidWlanBroadcastReceiver.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.App;
using Android.Content;
diff --git a/Sensus.Android.Shared/UI/SliderInputEffect.cs b/Sensus.Android.Shared/UI/SliderInputEffect.cs
index 73ef50591..f92006d07 100644
--- a/Sensus.Android.Shared/UI/SliderInputEffect.cs
+++ b/Sensus.Android.Shared/UI/SliderInputEffect.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.Widget;
using Android.Graphics.Drawables;
@@ -70,4 +75,4 @@ protected override void OnDetached()
{
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Shared/UI/TextCellDisposedFix.cs b/Sensus.Android.Shared/UI/TextCellDisposedFix.cs
index 04fe073da..cbf65487b 100644
--- a/Sensus.Android.Shared/UI/TextCellDisposedFix.cs
+++ b/Sensus.Android.Shared/UI/TextCellDisposedFix.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus.Android;
using System;
@@ -41,4 +46,4 @@ protected override void OnCellPropertyChanged(object sender, PropertyChangedEven
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Tests/AndroidMainActivity.cs b/Sensus.Android.Tests/AndroidMainActivity.cs
index bd20cadc2..3cb375885 100644
--- a/Sensus.Android.Tests/AndroidMainActivity.cs
+++ b/Sensus.Android.Tests/AndroidMainActivity.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System.Reflection;
using Android.App;
@@ -75,4 +80,4 @@ public void GetActivityResultAsync(Intent intent, AndroidActivityResultRequestCo
throw new NotImplementedException();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Tests/Properties/AssemblyInfo.cs b/Sensus.Android.Tests/Properties/AssemblyInfo.cs
index 6dc66d921..1369bbc75 100644
--- a/Sensus.Android.Tests/Properties/AssemblyInfo.cs
+++ b/Sensus.Android.Tests/Properties/AssemblyInfo.cs
@@ -1,4 +1,22 @@
-using System.Reflection;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+using System.Reflection;
using System.Runtime.CompilerServices;
using Android.App;
diff --git a/Sensus.Android.Tests/Tests/Concurrent/MainConcurrentTests.cs b/Sensus.Android.Tests/Tests/Concurrent/MainConcurrentTests.cs
index 845b7eacd..fb9782299 100644
--- a/Sensus.Android.Tests/Tests/Concurrent/MainConcurrentTests.cs
+++ b/Sensus.Android.Tests/Tests/Concurrent/MainConcurrentTests.cs
@@ -1,27 +1,32 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using Sensus.Android.Concurrent;
-using Sensus.Tests.Concurrent;
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using Sensus.Android.Concurrent;
+using Sensus.Tests.Concurrent;
+
namespace Sensus.Android.Tests.Concurrent
{
- public class MainConcurrentTests : ConcurrentTests
- {
- public MainConcurrentTests() : base(new MainConcurrent(1000))
- {
-
+ public class MainConcurrentTests : ConcurrentTests
+ {
+ public MainConcurrentTests() : base(new MainConcurrent(1000))
+ {
+
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android.Tests/Tests/Extensions/DateTimeExtensionsTests.cs b/Sensus.Android.Tests/Tests/Extensions/DateTimeExtensionsTests.cs
index e41f8959f..1ba4f774e 100644
--- a/Sensus.Android.Tests/Tests/Extensions/DateTimeExtensionsTests.cs
+++ b/Sensus.Android.Tests/Tests/Extensions/DateTimeExtensionsTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Java.Lang;
@@ -33,4 +38,4 @@ public void ToJavaTime()
Assert.Equal(currentTimeMillis, currentLocalTime.ToJavaCurrentTimeMillis());
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Android/AndroidMainActivity.cs b/Sensus.Android/AndroidMainActivity.cs
index bb1e97ea2..ff1715b50 100644
--- a/Sensus.Android/AndroidMainActivity.cs
+++ b/Sensus.Android/AndroidMainActivity.cs
@@ -1,414 +1,419 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System;
using System.IO;
-using System.Threading;
-using Android.OS;
-using Android.App;
-using Android.Widget;
-using Android.Content;
-using Android.Content.PM;
-using Sensus.UI;
-using Sensus.Context;
-using Xamarin;
-using Xamarin.Forms;
-using Xamarin.Facebook;
-using Xamarin.Forms.Platform.Android;
-using Plugin.CurrentActivity;
-using System.Threading.Tasks;
-using Sensus.Exceptions;
-using Sensus.Notifications;
-
-#if __ANDROID_23__
-using Plugin.Permissions;
-#endif
-
-[assembly: MetaData("com.facebook.sdk.ApplicationId", Value = "@string/app_id")]
-[assembly: UsesPermission(Microsoft.Band.BandClientManager.BindBandService)]
-
-namespace Sensus.Android
-{
- [Activity(Label = "@string/app_name", MainLauncher = true, LaunchMode = LaunchMode.SingleTask, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation)]
- [IntentFilter(new string[] { Intent.ActionView }, Categories = new string[] { Intent.CategoryDefault, Intent.CategoryBrowsable }, DataScheme = "https", DataHost = "*", DataPathPattern = ".*\\\\.json")] // protocols downloaded from an https web link
- [IntentFilter(new string[] { Intent.ActionView }, Categories = new string[] { Intent.CategoryDefault }, DataMimeType = "application/json")] // protocols obtained from "file" and "content" schemes: http://developer.android.com/guide/components/intents-filters.html#DataTest
- public class AndroidMainActivity : FormsAppCompatActivity
- {
- private AndroidSensusServiceConnection _serviceConnection;
- private ManualResetEvent _activityResultWait;
- private AndroidActivityResultRequestCode _activityResultRequestCode;
- private Tuple _activityResult;
- private ICallbackManager _facebookCallbackManager;
- private ManualResetEvent _serviceBindWait;
-
- private readonly object _locker = new object();
-
- public ICallbackManager FacebookCallbackManager
- {
- get { return _facebookCallbackManager; }
- }
-
- protected override async void OnCreate(Bundle savedInstanceState)
- {
- Console.Error.WriteLine("--------------------------- Creating activity ---------------------------");
-
- // set the layout resources first
- ToolbarResource = Resource.Layout.Toolbar;
- TabLayoutResource = Resource.Layout.Tabbar;
-
- base.OnCreate(savedInstanceState);
-
- _activityResultWait = new ManualResetEvent(false);
- _facebookCallbackManager = CallbackManagerFactory.Create();
- _serviceBindWait = new ManualResetEvent(false);
-
- Window.AddFlags(global::Android.Views.WindowManagerFlags.DismissKeyguard);
- Window.AddFlags(global::Android.Views.WindowManagerFlags.ShowWhenLocked);
- Window.AddFlags(global::Android.Views.WindowManagerFlags.TurnScreenOn);
-
- Forms.Init(this, savedInstanceState);
- FormsMaps.Init(this, savedInstanceState);
- ZXing.Net.Mobile.Forms.Android.Platform.Init();
- CrossCurrentActivity.Current.Init(this, savedInstanceState);
-
-#if UI_TESTING
- Forms.ViewInitialized += (sender, e) =>
- {
- if (!string.IsNullOrWhiteSpace(e.View.StyleId))
- {
- e.NativeView.ContentDescription = e.View.StyleId;
- }
- };
-#endif
-
- LoadApplication(new App());
-
- _serviceConnection = new AndroidSensusServiceConnection();
- _serviceConnection.ServiceConnected += (o, e) =>
- {
- // it's happened that the service is created / started after the service helper is disposed: https://insights.xamarin.com/app/Sensus-Production/issues/46
- // binding to the service in such a situation can result in a null service helper within the binder. if the service helper was disposed, then the goal is
- // to close down sensus. so finish the activity.
- if (e.Binder.SensusServiceHelper == null)
- {
- Finish();
- return;
- }
-
- // tell the service to finish this activity when it is stopped
- e.Binder.ServiceStopAction = Finish;
-
- // signal the activity that the service has been bound
- _serviceBindWait.Set();
-
- // if we're UI testing, try to load and run the UI testing protocol from the embedded assets
-#if UI_TESTING
- using (Stream protocolFile = Assets.Open("UiTestingProtocol.json"))
- {
- Protocol.RunUiTestingProtocolAsync(protocolFile);
- }
-#endif
- };
-
- // the following is fired if the process hosting the service crashes or is killed.
- _serviceConnection.ServiceDisconnected += (o, e) =>
- {
- Toast.MakeText(this, "The Sensus service has crashed.", ToastLength.Long);
- DisconnectFromService();
- Finish();
- };
-
- await OpenIntentAsync(Intent);
- }
-
- protected override void OnStart()
- {
- Console.Error.WriteLine("--------------------------- Starting activity ---------------------------");
-
- base.OnStart();
- }
-
- protected override async void OnResume()
- {
- Console.Error.WriteLine("--------------------------- Resuming activity ---------------------------");
-
- base.OnResume();
-
- // temporarily hide UI while we bind to service. allowing the user to click around before the service helper is initialized
- // may result in a crash.
- (Xamarin.Forms.Application.Current as App).MasterPage.IsVisible = false;
- (Xamarin.Forms.Application.Current as App).DetailPage.IsVisible = false;
-
- // make sure that the service is running and bound any time the activity is resumed. the service is both started
- // and bound, as we'd like the service to remain running and available to other apps even if the current activity unbinds.
- Intent serviceIntent = AndroidSensusService.StartService(this, false);
- BindService(serviceIntent, _serviceConnection, Bind.AboveClient);
-
- // start new task to wait for connection, since we're currently on the UI thread, which the service connection needs in order to complete.
- await Task.Run(() =>
- {
- // we've not seen the binding take more than a second or two; however, we want to be very careful not to block indefinitely
- // here becaus the UI is currently disabled. if for some strange reason the binding does not work, bail out after 10 seconds
- // and let the user interact with the UI. most likely, a crash will be coming very soon in this case, as the sensus service
- // will probably not be running. again, this has not occurred in practice, but allowing the crash to occur will send us information
- // through the crash analytics service and we'll be able to track it
- _serviceBindWait.WaitOne(TimeSpan.FromSeconds(10000));
-
- SensusServiceHelper.Get().ClearPendingSurveysNotification();
-
- // now that the service connection has been established, reenable UI.
- try
- {
- SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
- {
- (Xamarin.Forms.Application.Current as App).MasterPage.IsVisible = true;
- (Xamarin.Forms.Application.Current as App).DetailPage.IsVisible = true;
- });
- }
- catch (Exception)
- {
- }
- });
- }
-
- protected override void OnPause()
- {
- Console.Error.WriteLine("--------------------------- Pausing activity ---------------------------");
-
- base.OnPause();
-
- // we disconnect from the service within onpause because onresume always blocks the user while rebinding
- // to the service. conditions (the bind wait handle and service connection) need to be ready for onresume
- // and this is the only place to establish those conditions.
- DisconnectFromService();
- }
-
- protected override async void OnStop()
- {
- Console.Error.WriteLine("--------------------------- Stopping activity ---------------------------");
-
- base.OnStop();
-
- SensusServiceHelper serviceHelper = SensusServiceHelper.Get();
-
- if (serviceHelper != null)
- {
- await serviceHelper.SaveAsync();
- }
- }
-
- protected override void OnDestroy()
- {
- Console.Error.WriteLine("--------------------------- Destroying activity ---------------------------");
-
- base.OnDestroy();
-
- // if the activity is destroyed, reset the service connection stop action to be null so that the service doesn't try to
- // finish a destroyed activity if/when the service stops.
- if (_serviceConnection.Binder != null)
- {
- _serviceConnection.Binder.ServiceStopAction = null;
- }
- }
-
- private void DisconnectFromService()
- {
- _serviceBindWait.Reset();
-
- if (_serviceConnection.Binder != null)
- {
- try
- {
- UnbindService(_serviceConnection);
- }
- catch (Exception ex)
- {
- SensusServiceHelper.Get().Logger.Log("Failed to disconnection from service: " + ex.Message, LoggingLevel.Normal, GetType());
- }
- }
- }
-
- public override void OnWindowFocusChanged(bool hasFocus)
- {
- base.OnWindowFocusChanged(hasFocus);
-
- // the service helper is responsible for running actions that depend on the main activity. if the main activity
- // is not showing, the service helper starts the main activity and then runs requested actions. there is a race
- // condition between actions that wish to show a dialog (e.g., starting speech recognition) and the display of
- // the activity. in order to ensure that the activity is showing before any actions are run, we override this
- // focus changed event and let the service helper know when the activity is focused and when it is not. this
- // way, any actions that the service helper runs will certainly be run after the main activity is running
- // and focused.
- AndroidSensusServiceHelper serviceHelper = SensusServiceHelper.Get() as AndroidSensusServiceHelper;
-
- if (serviceHelper != null)
- {
- if (hasFocus)
- {
- serviceHelper.SetFocusedMainActivity(this);
- }
- else
- {
- serviceHelper.SetFocusedMainActivity(null);
- }
- }
- }
-
- #region intent handling
-
- protected override async void OnNewIntent(Intent intent)
- {
- base.OnNewIntent(intent);
-
- await OpenIntentAsync(intent);
- }
-
- private async Task OpenIntentAsync(Intent intent)
- {
- // wait for service helper to be initialized, since this method might be called before the service starts up
- // and initializes the service helper.
- int timeToWaitMS = 60000;
- int waitIntervalMS = 1000;
- while (SensusServiceHelper.Get() == null && timeToWaitMS > 0)
- {
- await Task.Delay(waitIntervalMS);
- timeToWaitMS -= waitIntervalMS;
- }
-
- if (SensusServiceHelper.Get() == null)
- {
- // don't use SensusServiceHelper.Get().FlashNotificationAsync because service helper is null
- RunOnUiThread(() =>
- {
- Toast.MakeText(this, "Failed to get service helper. Cannot open Intent.", ToastLength.Long);
- });
-
- return;
- }
-
- DisplayPage displayPage;
-
- // open page to view protocol if a protocol was passed to us
- if (intent.Data != null)
- {
- try
- {
- global::Android.Net.Uri dataURI = intent.Data;
-
- Protocol protocol = null;
-
- if (intent.Scheme == "https")
- {
- protocol = await Protocol.DeserializeAsync(new Uri(dataURI.ToString()));
- }
- else if (intent.Scheme == "content" || intent.Scheme == "file")
- {
- byte[] bytes = null;
-
- try
- {
- MemoryStream memoryStream = new MemoryStream();
- Stream inputStream = ContentResolver.OpenInputStream(dataURI);
- inputStream.CopyTo(memoryStream);
- inputStream.Close();
- bytes = memoryStream.ToArray();
- }
- catch (Exception ex)
- {
- throw new Exception("Failed to read bytes from local file URI \"" + dataURI + "\": " + ex.Message);
- }
-
- if (bytes != null)
- {
- protocol = await Protocol.DeserializeAsync(bytes);
- }
- }
- else
- {
- throw new Exception("Sensus didn't know what to do with URI \"" + dataURI + "\".");
- }
-
- await Protocol.DisplayAndStartAsync(protocol);
- }
- catch (Exception ex)
- {
- SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
- {
- new AlertDialog.Builder(this).SetTitle("Failed to start protocol").SetMessage(ex.Message).Show();
- SensusServiceHelper.Get().Logger.Log(ex.Message, LoggingLevel.Normal, GetType());
- });
- }
- }
- else if (Enum.TryParse(intent.GetStringExtra(Notifier.DISPLAY_PAGE_KEY), out displayPage))
- {
- SensusContext.Current.Notifier.OpenDisplayPage(displayPage);
- }
- }
-
- #endregion
-
- #region activity results
-
- public void GetActivityResultAsync(Intent intent, AndroidActivityResultRequestCode requestCode, Action> callback)
- {
- Task.Run(() =>
- {
- lock (_locker)
- {
- _activityResultRequestCode = requestCode;
- _activityResult = null;
-
- _activityResultWait.Reset();
-
- try
- {
- StartActivityForResult(intent, (int)requestCode);
- }
- catch (Exception ex)
- {
- SensusException.Report(ex);
- _activityResultWait.Set();
- }
-
- _activityResultWait.WaitOne();
-
- callback(_activityResult);
- }
- });
- }
-
- protected override void OnActivityResult(int requestCode, Result resultCode, Intent data)
- {
- base.OnActivityResult(requestCode, resultCode, data);
-
- if (requestCode == (int)_activityResultRequestCode)
- {
- _activityResult = new Tuple(resultCode, data);
- _activityResultWait.Set();
- }
-
- _facebookCallbackManager.OnActivityResult(requestCode, (int)resultCode, data);
- }
-
-#if __ANDROID_23__
- public override void OnRequestPermissionsResult(int requestCode, string[] permissions, Permission[] grantResults)
- {
- PermissionsImplementation.Current.OnRequestPermissionsResult(requestCode, permissions, grantResults);
- ZXing.Net.Mobile.Android.PermissionsHandler.OnRequestPermissionsResult(requestCode, permissions, grantResults);
- }
-#endif
-
- #endregion
- }
-}
\ No newline at end of file
+using System.Threading;
+using Android.OS;
+using Android.App;
+using Android.Widget;
+using Android.Content;
+using Android.Content.PM;
+using Sensus.UI;
+using Sensus.Context;
+using Xamarin;
+using Xamarin.Forms;
+using Xamarin.Facebook;
+using Xamarin.Forms.Platform.Android;
+using Plugin.CurrentActivity;
+using System.Threading.Tasks;
+using Sensus.Exceptions;
+using Sensus.Notifications;
+
+#if __ANDROID_23__
+using Plugin.Permissions;
+#endif
+
+[assembly: MetaData("com.facebook.sdk.ApplicationId", Value = "@string/app_id")]
+[assembly: UsesPermission(Microsoft.Band.BandClientManager.BindBandService)]
+
+namespace Sensus.Android
+{
+ [Activity(Label = "@string/app_name", MainLauncher = true, LaunchMode = LaunchMode.SingleTask, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation)]
+ [IntentFilter(new string[] { Intent.ActionView }, Categories = new string[] { Intent.CategoryDefault, Intent.CategoryBrowsable }, DataScheme = "https", DataHost = "*", DataPathPattern = ".*\\\\.json")] // protocols downloaded from an https web link
+ [IntentFilter(new string[] { Intent.ActionView }, Categories = new string[] { Intent.CategoryDefault }, DataMimeType = "application/json")] // protocols obtained from "file" and "content" schemes: http://developer.android.com/guide/components/intents-filters.html#DataTest
+ public class AndroidMainActivity : FormsAppCompatActivity
+ {
+ private AndroidSensusServiceConnection _serviceConnection;
+ private ManualResetEvent _activityResultWait;
+ private AndroidActivityResultRequestCode _activityResultRequestCode;
+ private Tuple _activityResult;
+ private ICallbackManager _facebookCallbackManager;
+ private ManualResetEvent _serviceBindWait;
+
+ private readonly object _locker = new object();
+
+ public ICallbackManager FacebookCallbackManager
+ {
+ get { return _facebookCallbackManager; }
+ }
+
+ protected override async void OnCreate(Bundle savedInstanceState)
+ {
+ Console.Error.WriteLine("--------------------------- Creating activity ---------------------------");
+
+ // set the layout resources first
+ ToolbarResource = Resource.Layout.Toolbar;
+ TabLayoutResource = Resource.Layout.Tabbar;
+
+ base.OnCreate(savedInstanceState);
+
+ _activityResultWait = new ManualResetEvent(false);
+ _facebookCallbackManager = CallbackManagerFactory.Create();
+ _serviceBindWait = new ManualResetEvent(false);
+
+ Window.AddFlags(global::Android.Views.WindowManagerFlags.DismissKeyguard);
+ Window.AddFlags(global::Android.Views.WindowManagerFlags.ShowWhenLocked);
+ Window.AddFlags(global::Android.Views.WindowManagerFlags.TurnScreenOn);
+
+ Forms.Init(this, savedInstanceState);
+ FormsMaps.Init(this, savedInstanceState);
+ ZXing.Net.Mobile.Forms.Android.Platform.Init();
+ CrossCurrentActivity.Current.Init(this, savedInstanceState);
+
+#if UI_TESTING
+ Forms.ViewInitialized += (sender, e) =>
+ {
+ if (!string.IsNullOrWhiteSpace(e.View.StyleId))
+ {
+ e.NativeView.ContentDescription = e.View.StyleId;
+ }
+ };
+#endif
+
+ LoadApplication(new App());
+
+ _serviceConnection = new AndroidSensusServiceConnection();
+ _serviceConnection.ServiceConnected += (o, e) =>
+ {
+ // it's happened that the service is created / started after the service helper is disposed: https://insights.xamarin.com/app/Sensus-Production/issues/46
+ // binding to the service in such a situation can result in a null service helper within the binder. if the service helper was disposed, then the goal is
+ // to close down sensus. so finish the activity.
+ if (e.Binder.SensusServiceHelper == null)
+ {
+ Finish();
+ return;
+ }
+
+ // tell the service to finish this activity when it is stopped
+ e.Binder.ServiceStopAction = Finish;
+
+ // signal the activity that the service has been bound
+ _serviceBindWait.Set();
+
+ // if we're UI testing, try to load and run the UI testing protocol from the embedded assets
+#if UI_TESTING
+ using (Stream protocolFile = Assets.Open("UiTestingProtocol.json"))
+ {
+ Protocol.RunUiTestingProtocolAsync(protocolFile);
+ }
+#endif
+ };
+
+ // the following is fired if the process hosting the service crashes or is killed.
+ _serviceConnection.ServiceDisconnected += (o, e) =>
+ {
+ Toast.MakeText(this, "The Sensus service has crashed.", ToastLength.Long);
+ DisconnectFromService();
+ Finish();
+ };
+
+ await OpenIntentAsync(Intent);
+ }
+
+ protected override void OnStart()
+ {
+ Console.Error.WriteLine("--------------------------- Starting activity ---------------------------");
+
+ base.OnStart();
+ }
+
+ protected override async void OnResume()
+ {
+ Console.Error.WriteLine("--------------------------- Resuming activity ---------------------------");
+
+ base.OnResume();
+
+ // temporarily hide UI while we bind to service. allowing the user to click around before the service helper is initialized
+ // may result in a crash.
+ (Xamarin.Forms.Application.Current as App).MasterPage.IsVisible = false;
+ (Xamarin.Forms.Application.Current as App).DetailPage.IsVisible = false;
+
+ // make sure that the service is running and bound any time the activity is resumed. the service is both started
+ // and bound, as we'd like the service to remain running and available to other apps even if the current activity unbinds.
+ Intent serviceIntent = AndroidSensusService.StartService(this, false);
+ BindService(serviceIntent, _serviceConnection, Bind.AboveClient);
+
+ // start new task to wait for connection, since we're currently on the UI thread, which the service connection needs in order to complete.
+ await Task.Run(() =>
+ {
+ // we've not seen the binding take more than a second or two; however, we want to be very careful not to block indefinitely
+ // here becaus the UI is currently disabled. if for some strange reason the binding does not work, bail out after 10 seconds
+ // and let the user interact with the UI. most likely, a crash will be coming very soon in this case, as the sensus service
+ // will probably not be running. again, this has not occurred in practice, but allowing the crash to occur will send us information
+ // through the crash analytics service and we'll be able to track it
+ _serviceBindWait.WaitOne(TimeSpan.FromSeconds(10000));
+
+ SensusServiceHelper.Get().ClearPendingSurveysNotification();
+
+ // now that the service connection has been established, reenable UI.
+ try
+ {
+ SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
+ {
+ (Xamarin.Forms.Application.Current as App).MasterPage.IsVisible = true;
+ (Xamarin.Forms.Application.Current as App).DetailPage.IsVisible = true;
+ });
+ }
+ catch (Exception)
+ {
+ }
+ });
+ }
+
+ protected override void OnPause()
+ {
+ Console.Error.WriteLine("--------------------------- Pausing activity ---------------------------");
+
+ base.OnPause();
+
+ // we disconnect from the service within onpause because onresume always blocks the user while rebinding
+ // to the service. conditions (the bind wait handle and service connection) need to be ready for onresume
+ // and this is the only place to establish those conditions.
+ DisconnectFromService();
+ }
+
+ protected override async void OnStop()
+ {
+ Console.Error.WriteLine("--------------------------- Stopping activity ---------------------------");
+
+ base.OnStop();
+
+ SensusServiceHelper serviceHelper = SensusServiceHelper.Get();
+
+ if (serviceHelper != null)
+ {
+ await serviceHelper.SaveAsync();
+ }
+ }
+
+ protected override void OnDestroy()
+ {
+ Console.Error.WriteLine("--------------------------- Destroying activity ---------------------------");
+
+ base.OnDestroy();
+
+ // if the activity is destroyed, reset the service connection stop action to be null so that the service doesn't try to
+ // finish a destroyed activity if/when the service stops.
+ if (_serviceConnection.Binder != null)
+ {
+ _serviceConnection.Binder.ServiceStopAction = null;
+ }
+ }
+
+ private void DisconnectFromService()
+ {
+ _serviceBindWait.Reset();
+
+ if (_serviceConnection.Binder != null)
+ {
+ try
+ {
+ UnbindService(_serviceConnection);
+ }
+ catch (Exception ex)
+ {
+ SensusServiceHelper.Get().Logger.Log("Failed to disconnection from service: " + ex.Message, LoggingLevel.Normal, GetType());
+ }
+ }
+ }
+
+ public override void OnWindowFocusChanged(bool hasFocus)
+ {
+ base.OnWindowFocusChanged(hasFocus);
+
+ // the service helper is responsible for running actions that depend on the main activity. if the main activity
+ // is not showing, the service helper starts the main activity and then runs requested actions. there is a race
+ // condition between actions that wish to show a dialog (e.g., starting speech recognition) and the display of
+ // the activity. in order to ensure that the activity is showing before any actions are run, we override this
+ // focus changed event and let the service helper know when the activity is focused and when it is not. this
+ // way, any actions that the service helper runs will certainly be run after the main activity is running
+ // and focused.
+ AndroidSensusServiceHelper serviceHelper = SensusServiceHelper.Get() as AndroidSensusServiceHelper;
+
+ if (serviceHelper != null)
+ {
+ if (hasFocus)
+ {
+ serviceHelper.SetFocusedMainActivity(this);
+ }
+ else
+ {
+ serviceHelper.SetFocusedMainActivity(null);
+ }
+ }
+ }
+
+ #region intent handling
+
+ protected override async void OnNewIntent(Intent intent)
+ {
+ base.OnNewIntent(intent);
+
+ await OpenIntentAsync(intent);
+ }
+
+ private async Task OpenIntentAsync(Intent intent)
+ {
+ // wait for service helper to be initialized, since this method might be called before the service starts up
+ // and initializes the service helper.
+ int timeToWaitMS = 60000;
+ int waitIntervalMS = 1000;
+ while (SensusServiceHelper.Get() == null && timeToWaitMS > 0)
+ {
+ await Task.Delay(waitIntervalMS);
+ timeToWaitMS -= waitIntervalMS;
+ }
+
+ if (SensusServiceHelper.Get() == null)
+ {
+ // don't use SensusServiceHelper.Get().FlashNotificationAsync because service helper is null
+ RunOnUiThread(() =>
+ {
+ Toast.MakeText(this, "Failed to get service helper. Cannot open Intent.", ToastLength.Long);
+ });
+
+ return;
+ }
+
+ DisplayPage displayPage;
+
+ // open page to view protocol if a protocol was passed to us
+ if (intent.Data != null)
+ {
+ try
+ {
+ global::Android.Net.Uri dataURI = intent.Data;
+
+ Protocol protocol = null;
+
+ if (intent.Scheme == "https")
+ {
+ protocol = await Protocol.DeserializeAsync(new Uri(dataURI.ToString()));
+ }
+ else if (intent.Scheme == "content" || intent.Scheme == "file")
+ {
+ byte[] bytes = null;
+
+ try
+ {
+ MemoryStream memoryStream = new MemoryStream();
+ Stream inputStream = ContentResolver.OpenInputStream(dataURI);
+ inputStream.CopyTo(memoryStream);
+ inputStream.Close();
+ bytes = memoryStream.ToArray();
+ }
+ catch (Exception ex)
+ {
+ throw new Exception("Failed to read bytes from local file URI \"" + dataURI + "\": " + ex.Message);
+ }
+
+ if (bytes != null)
+ {
+ protocol = await Protocol.DeserializeAsync(bytes);
+ }
+ }
+ else
+ {
+ throw new Exception("Sensus didn't know what to do with URI \"" + dataURI + "\".");
+ }
+
+ await Protocol.DisplayAndStartAsync(protocol);
+ }
+ catch (Exception ex)
+ {
+ SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
+ {
+ new AlertDialog.Builder(this).SetTitle("Failed to start protocol").SetMessage(ex.Message).Show();
+ SensusServiceHelper.Get().Logger.Log(ex.Message, LoggingLevel.Normal, GetType());
+ });
+ }
+ }
+ else if (Enum.TryParse(intent.GetStringExtra(Notifier.DISPLAY_PAGE_KEY), out displayPage))
+ {
+ SensusContext.Current.Notifier.OpenDisplayPage(displayPage);
+ }
+ }
+
+ #endregion
+
+ #region activity results
+
+ public void GetActivityResultAsync(Intent intent, AndroidActivityResultRequestCode requestCode, Action> callback)
+ {
+ Task.Run(() =>
+ {
+ lock (_locker)
+ {
+ _activityResultRequestCode = requestCode;
+ _activityResult = null;
+
+ _activityResultWait.Reset();
+
+ try
+ {
+ StartActivityForResult(intent, (int)requestCode);
+ }
+ catch (Exception ex)
+ {
+ SensusException.Report(ex);
+ _activityResultWait.Set();
+ }
+
+ _activityResultWait.WaitOne();
+
+ callback(_activityResult);
+ }
+ });
+ }
+
+ protected override void OnActivityResult(int requestCode, Result resultCode, Intent data)
+ {
+ base.OnActivityResult(requestCode, resultCode, data);
+
+ if (requestCode == (int)_activityResultRequestCode)
+ {
+ _activityResult = new Tuple(resultCode, data);
+ _activityResultWait.Set();
+ }
+
+ _facebookCallbackManager.OnActivityResult(requestCode, (int)resultCode, data);
+ }
+
+#if __ANDROID_23__
+ public override void OnRequestPermissionsResult(int requestCode, string[] permissions, Permission[] grantResults)
+ {
+ PermissionsImplementation.Current.OnRequestPermissionsResult(requestCode, permissions, grantResults);
+ ZXing.Net.Mobile.Android.PermissionsHandler.OnRequestPermissionsResult(requestCode, permissions, grantResults);
+ }
+#endif
+
+ #endregion
+ }
+}
diff --git a/Sensus.Android/Properties/AssemblyInfo.cs b/Sensus.Android/Properties/AssemblyInfo.cs
index c840d4f20..305dbbf37 100644
--- a/Sensus.Android/Properties/AssemblyInfo.cs
+++ b/Sensus.Android/Properties/AssemblyInfo.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Android.App;
using System.Reflection;
@@ -34,4 +39,4 @@
[assembly: Application(Debuggable = true)]
#else
[assembly: Application(Debuggable = false)]
-#endif
\ No newline at end of file
+#endif
diff --git a/Sensus.Android/Sensus.licenseheader b/Sensus.Android/Sensus.licenseheader
index accb4f916..1cb079f29 100644
--- a/Sensus.Android/Sensus.licenseheader
+++ b/Sensus.Android/Sensus.licenseheader
@@ -1,14 +1,19 @@
extensions: .cs
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
\ No newline at end of file
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
\ No newline at end of file
diff --git a/Sensus.Shared.NuGet/Activities.cs b/Sensus.Shared.NuGet/Activities.cs
index c4677f3cd..ba847ea32 100644
--- a/Sensus.Shared.NuGet/Activities.cs
+++ b/Sensus.Shared.NuGet/Activities.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.Movement
{
@@ -28,4 +33,4 @@ public enum Activities
Unknown,
Walking
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ActivityConfidence.cs b/Sensus.Shared.NuGet/ActivityConfidence.cs
index 0af6db1c2..32e25ad65 100644
--- a/Sensus.Shared.NuGet/ActivityConfidence.cs
+++ b/Sensus.Shared.NuGet/ActivityConfidence.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.Movement
{
diff --git a/Sensus.Shared.NuGet/ActivityPhase.cs b/Sensus.Shared.NuGet/ActivityPhase.cs
index bf455d139..24a446ec7 100644
--- a/Sensus.Shared.NuGet/ActivityPhase.cs
+++ b/Sensus.Shared.NuGet/ActivityPhase.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.Movement
{
diff --git a/Sensus.Shared.NuGet/ActivityState.cs b/Sensus.Shared.NuGet/ActivityState.cs
index 8fdf9b1f6..ac4ab6ad3 100644
--- a/Sensus.Shared.NuGet/ActivityState.cs
+++ b/Sensus.Shared.NuGet/ActivityState.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.Movement
{
diff --git a/Sensus.Shared.NuGet/EstimoteBeaconProximityEvent.cs b/Sensus.Shared.NuGet/EstimoteBeaconProximityEvent.cs
index c13a62180..2eaab4e6b 100644
--- a/Sensus.Shared.NuGet/EstimoteBeaconProximityEvent.cs
+++ b/Sensus.Shared.NuGet/EstimoteBeaconProximityEvent.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.Location
{
diff --git a/Sensus.Shared.NuGet/IAccelerometerDatum.cs b/Sensus.Shared.NuGet/IAccelerometerDatum.cs
index 5b2745ea5..2990ad56f 100644
--- a/Sensus.Shared.NuGet/IAccelerometerDatum.cs
+++ b/Sensus.Shared.NuGet/IAccelerometerDatum.cs
@@ -1,4 +1,22 @@
-namespace Sensus.Probes.Movement
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Movement
{
public interface IAccelerometerDatum : IDatum
{
@@ -6,4 +24,4 @@ public interface IAccelerometerDatum : IDatum
double Y { get; set; }
double Z { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IActivityDatum.cs b/Sensus.Shared.NuGet/IActivityDatum.cs
index 2d6954c7a..e4cd23404 100644
--- a/Sensus.Shared.NuGet/IActivityDatum.cs
+++ b/Sensus.Shared.NuGet/IActivityDatum.cs
@@ -1,4 +1,22 @@
-namespace Sensus.Probes.Movement
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Movement
{
public interface IActivityDatum : IDatum
{
@@ -10,4 +28,4 @@ public interface IActivityDatum : IDatum
Activities ActivityContinuing { get; }
Activities ActivityStopping { get; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IAltitudeDatum.cs b/Sensus.Shared.NuGet/IAltitudeDatum.cs
index df8c70a07..4e5102689 100644
--- a/Sensus.Shared.NuGet/IAltitudeDatum.cs
+++ b/Sensus.Shared.NuGet/IAltitudeDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Location
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Location
{
public interface IAltitudeDatum : IDatum
{
double Altitude { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IAmbientTemperatureDatum.cs b/Sensus.Shared.NuGet/IAmbientTemperatureDatum.cs
index cb583bee8..0aeddce16 100644
--- a/Sensus.Shared.NuGet/IAmbientTemperatureDatum.cs
+++ b/Sensus.Shared.NuGet/IAmbientTemperatureDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Context
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Context
{
public interface IAmbientTemperatureDatum : IDatum
{
double DegreesCelsius { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IBatteryDatum.cs b/Sensus.Shared.NuGet/IBatteryDatum.cs
index c1e4b94e2..6208ea8d0 100644
--- a/Sensus.Shared.NuGet/IBatteryDatum.cs
+++ b/Sensus.Shared.NuGet/IBatteryDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Device
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Device
{
public interface IBatteryDatum : IDatum
{
double Level { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IBluetoothDeviceProximityDatum.cs b/Sensus.Shared.NuGet/IBluetoothDeviceProximityDatum.cs
index 21bd1d1de..301a8228c 100644
--- a/Sensus.Shared.NuGet/IBluetoothDeviceProximityDatum.cs
+++ b/Sensus.Shared.NuGet/IBluetoothDeviceProximityDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Context
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Context
{
public interface IBluetoothDeviceProximityDatum : IDatum
{
string EncounteredDeviceId { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ICellTowerDatum.cs b/Sensus.Shared.NuGet/ICellTowerDatum.cs
index 13955ee63..ca6ad2c1b 100644
--- a/Sensus.Shared.NuGet/ICellTowerDatum.cs
+++ b/Sensus.Shared.NuGet/ICellTowerDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Network
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Network
{
public interface ICellTowerDatum : IDatum
{
string CellTower { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ICompassDatum.cs b/Sensus.Shared.NuGet/ICompassDatum.cs
index 5d057f5ac..ae328400d 100644
--- a/Sensus.Shared.NuGet/ICompassDatum.cs
+++ b/Sensus.Shared.NuGet/ICompassDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Location
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Location
{
public interface ICompassDatum : IDatum
{
double Heading { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IDatum.cs b/Sensus.Shared.NuGet/IDatum.cs
index 39e1453f6..7e3cdbdb6 100644
--- a/Sensus.Shared.NuGet/IDatum.cs
+++ b/Sensus.Shared.NuGet/IDatum.cs
@@ -1,4 +1,22 @@
-using System;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+using System;
namespace Sensus
{
@@ -13,4 +31,4 @@ public interface IDatum
string DeviceModel { get; set; }
string OperatingSystem { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IEstimoteBeaconDatum.cs b/Sensus.Shared.NuGet/IEstimoteBeaconDatum.cs
index c8208369c..11bd0f0a5 100644
--- a/Sensus.Shared.NuGet/IEstimoteBeaconDatum.cs
+++ b/Sensus.Shared.NuGet/IEstimoteBeaconDatum.cs
@@ -1,4 +1,22 @@
-namespace Sensus.Probes.Location
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Location
{
public interface IEstimoteBeaconDatum : IDatum
{
@@ -8,4 +26,4 @@ public interface IEstimoteBeaconDatum : IDatum
EstimoteBeaconProximityEvent ProximityEvent { get; set; }
string EventSummary { get; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IGyroscopeDatum.cs b/Sensus.Shared.NuGet/IGyroscopeDatum.cs
index 263e3b1a1..a874a35f9 100644
--- a/Sensus.Shared.NuGet/IGyroscopeDatum.cs
+++ b/Sensus.Shared.NuGet/IGyroscopeDatum.cs
@@ -1,4 +1,22 @@
-namespace Sensus.Probes.Movement
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Movement
{
public interface IGyroscopeDatum : IDatum
{
@@ -6,4 +24,4 @@ public interface IGyroscopeDatum : IDatum
double Y { get; set; }
double Z { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IHumidityDatum.cs b/Sensus.Shared.NuGet/IHumidityDatum.cs
index 79aa0b654..b257b24e9 100644
--- a/Sensus.Shared.NuGet/IHumidityDatum.cs
+++ b/Sensus.Shared.NuGet/IHumidityDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Context
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Context
{
public interface IHumidityDatum : IDatum
{
double RelativeHumidity { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ILightDatum.cs b/Sensus.Shared.NuGet/ILightDatum.cs
index 6f688c66f..2abfd76de 100644
--- a/Sensus.Shared.NuGet/ILightDatum.cs
+++ b/Sensus.Shared.NuGet/ILightDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Context
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Context
{
public interface ILightDatum : IDatum
{
double Brightness { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ILocationDatum.cs b/Sensus.Shared.NuGet/ILocationDatum.cs
index b646f54cb..dfc96358e 100644
--- a/Sensus.Shared.NuGet/ILocationDatum.cs
+++ b/Sensus.Shared.NuGet/ILocationDatum.cs
@@ -1,8 +1,26 @@
-namespace Sensus.Probes.Location
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Location
{
public interface ILocationDatum : IDatum
{
double Latitude { get; set; }
double Longitude { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ILogger.cs b/Sensus.Shared.NuGet/ILogger.cs
index 4a0bf045a..145af4f28 100644
--- a/Sensus.Shared.NuGet/ILogger.cs
+++ b/Sensus.Shared.NuGet/ILogger.cs
@@ -1,4 +1,22 @@
-using System;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+using System;
namespace Sensus
{
@@ -8,4 +26,4 @@ public interface ILogger
void Log(string message, LoggingLevel level, Type callingType, bool throwException = false);
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IPointOfInterestProximityDatum.cs b/Sensus.Shared.NuGet/IPointOfInterestProximityDatum.cs
index 69fa15d5e..658c78cab 100644
--- a/Sensus.Shared.NuGet/IPointOfInterestProximityDatum.cs
+++ b/Sensus.Shared.NuGet/IPointOfInterestProximityDatum.cs
@@ -1,4 +1,22 @@
-namespace Sensus.Probes.Location
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Location
{
public interface IPointOfInterestProximityDatum : IDatum
{
@@ -10,4 +28,4 @@ public interface IPointOfInterestProximityDatum : IDatum
double TriggerDistanceMeters { get; set; }
ProximityThresholdDirection TriggerDistanceDirection { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IProximityDatum.cs b/Sensus.Shared.NuGet/IProximityDatum.cs
index 0504e8ad4..3d521492b 100644
--- a/Sensus.Shared.NuGet/IProximityDatum.cs
+++ b/Sensus.Shared.NuGet/IProximityDatum.cs
@@ -1,8 +1,26 @@
-namespace Sensus.Probes.Location
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Location
{
public interface IProximityDatum : IDatum
{
double Distance { get; set; }
double MaxDistance { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IScreenDatum.cs b/Sensus.Shared.NuGet/IScreenDatum.cs
index 3fe4aa544..4ab381f26 100644
--- a/Sensus.Shared.NuGet/IScreenDatum.cs
+++ b/Sensus.Shared.NuGet/IScreenDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Device
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Device
{
public interface IScreenDatum : IDatum
{
bool On { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IScript.cs b/Sensus.Shared.NuGet/IScript.cs
index cb3f2dddf..30dd7dea0 100644
--- a/Sensus.Shared.NuGet/IScript.cs
+++ b/Sensus.Shared.NuGet/IScript.cs
@@ -1,4 +1,22 @@
-using System;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+using System;
namespace Sensus.Probes.User.Scripts
{
@@ -12,4 +30,4 @@ public interface IScript
DateTime Birthdate { get; }
DateTime DisplayDateTime { get; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IScriptProbeAgent.cs b/Sensus.Shared.NuGet/IScriptProbeAgent.cs
index 34618e3a4..4c002ac0a 100644
--- a/Sensus.Shared.NuGet/IScriptProbeAgent.cs
+++ b/Sensus.Shared.NuGet/IScriptProbeAgent.cs
@@ -1,24 +1,42 @@
-using System;
-using System.Threading.Tasks;
-
-namespace Sensus.Probes.User.Scripts
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+using System;
+using System.Threading.Tasks;
+
+namespace Sensus.Probes.User.Scripts
{
///
/// Interface for all agents that control survey delivery within Sensus.
- ///
- public interface IScriptProbeAgent
+ ///
+ public interface IScriptProbeAgent
{
///
/// Readable description of the agent.
///
- /// The description.
+ /// The description.
string Description { get; }
///
/// Identifier of the agent (unique within the project).
///
- /// The identifier.
- string Id { get; }
+ /// The identifier.
+ string Id { get; }
///
/// Sets the policy of the agent
@@ -29,8 +47,8 @@ public interface IScriptProbeAgent
///
/// Asks the agent to observe an object that was just generated by Sensus.
///
- /// Datum.
- void Observe(IDatum datum);
+ /// Datum.
+ void Observe(IDatum datum);
///
/// Asks the agent whether an should be delivered at the present time as scheduled/triggered, or
@@ -43,7 +61,7 @@ public interface IScriptProbeAgent
/// * false, null: Do not deliver now and never deliver.
/// * false, DateTimeOffset.UtcNow + TimeSpan.FromMinutes(5): Reschedule survey to come back in 5 minutes
///
- /// Script.
+ /// Script.
Task> DeliverSurveyNow(IScript script);
///
@@ -57,6 +75,6 @@ public interface IScriptProbeAgent
/// Asks the agent to reset itself
///
/// A reference to the service helper, which provides access to the app's core functionality.
- void Reset(ISensusServiceHelper sensusServiceHelper);
- }
-}
\ No newline at end of file
+ void Reset(ISensusServiceHelper sensusServiceHelper);
+ }
+}
diff --git a/Sensus.Shared.NuGet/IScriptRunner.cs b/Sensus.Shared.NuGet/IScriptRunner.cs
index 4fac9be07..3b44279c0 100644
--- a/Sensus.Shared.NuGet/IScriptRunner.cs
+++ b/Sensus.Shared.NuGet/IScriptRunner.cs
@@ -1,4 +1,22 @@
-namespace Sensus.Probes.User.Scripts
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.User.Scripts
{
public interface IScriptRunner
{
@@ -8,4 +26,4 @@ public interface IScriptRunner
string TriggerWindowsString { get; set; }
int NonDowTriggerIntervalDays { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ISensusServiceHelper.cs b/Sensus.Shared.NuGet/ISensusServiceHelper.cs
index 31241feda..88744afd2 100644
--- a/Sensus.Shared.NuGet/ISensusServiceHelper.cs
+++ b/Sensus.Shared.NuGet/ISensusServiceHelper.cs
@@ -1,4 +1,22 @@
-using System.Threading.Tasks;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+using System.Threading.Tasks;
namespace Sensus
{
@@ -8,4 +26,4 @@ public interface ISensusServiceHelper
Task FlashNotificationAsync(string message);
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ISmsDatum.cs b/Sensus.Shared.NuGet/ISmsDatum.cs
index 8c5d2a34d..d72801648 100644
--- a/Sensus.Shared.NuGet/ISmsDatum.cs
+++ b/Sensus.Shared.NuGet/ISmsDatum.cs
@@ -1,4 +1,22 @@
-namespace Sensus.Probes.Communication
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Communication
{
public interface ISmsDatum : IDatum
{
@@ -7,4 +25,4 @@ public interface ISmsDatum : IDatum
string Message { get; set; }
bool ParticipantIsSender { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ISoundDatum.cs b/Sensus.Shared.NuGet/ISoundDatum.cs
index 18d0b2536..2eb32db52 100644
--- a/Sensus.Shared.NuGet/ISoundDatum.cs
+++ b/Sensus.Shared.NuGet/ISoundDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Context
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Context
{
public interface ISoundDatum : IDatum
{
double Decibels { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ISpeedDatum.cs b/Sensus.Shared.NuGet/ISpeedDatum.cs
index 653e9759f..b6e9e2c31 100644
--- a/Sensus.Shared.NuGet/ISpeedDatum.cs
+++ b/Sensus.Shared.NuGet/ISpeedDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Movement
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Movement
{
public interface ISpeedDatum : IDatum
{
double KPH { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ITelephonyDatum.cs b/Sensus.Shared.NuGet/ITelephonyDatum.cs
index 64b19f2c4..aaa5fdc36 100644
--- a/Sensus.Shared.NuGet/ITelephonyDatum.cs
+++ b/Sensus.Shared.NuGet/ITelephonyDatum.cs
@@ -1,4 +1,22 @@
-namespace Sensus.Probes.Communication
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Communication
{
public interface ITelephonyDatum : IDatum
{
@@ -6,4 +24,4 @@ public interface ITelephonyDatum : IDatum
TelephonyState State { get; set; }
string PhoneNumber { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/IWlanDatum.cs b/Sensus.Shared.NuGet/IWlanDatum.cs
index ccb176d69..b55c9c3a8 100644
--- a/Sensus.Shared.NuGet/IWlanDatum.cs
+++ b/Sensus.Shared.NuGet/IWlanDatum.cs
@@ -1,7 +1,25 @@
-namespace Sensus.Probes.Network
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+namespace Sensus.Probes.Network
{
public interface IWlanDatum : IDatum
{
string AccessPointBSSID { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/LoggingLevel.cs b/Sensus.Shared.NuGet/LoggingLevel.cs
index 257d012fa..f03b6680d 100644
--- a/Sensus.Shared.NuGet/LoggingLevel.cs
+++ b/Sensus.Shared.NuGet/LoggingLevel.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus
{
diff --git a/Sensus.Shared.NuGet/ProximityThresholdDirection.cs b/Sensus.Shared.NuGet/ProximityThresholdDirection.cs
index 7fcc56030..d699158ba 100644
--- a/Sensus.Shared.NuGet/ProximityThresholdDirection.cs
+++ b/Sensus.Shared.NuGet/ProximityThresholdDirection.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.Location
{
@@ -19,4 +24,4 @@ public enum ProximityThresholdDirection
Within,
Outside
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.NuGet/ScriptState.cs b/Sensus.Shared.NuGet/ScriptState.cs
index 9edd2fee2..cafee7960 100644
--- a/Sensus.Shared.NuGet/ScriptState.cs
+++ b/Sensus.Shared.NuGet/ScriptState.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.User.Scripts
{
diff --git a/Sensus.Shared.NuGet/TelephonyState.cs b/Sensus.Shared.NuGet/TelephonyState.cs
index aa8438711..7fbc27f3f 100644
--- a/Sensus.Shared.NuGet/TelephonyState.cs
+++ b/Sensus.Shared.NuGet/TelephonyState.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.Communication
{
diff --git a/Sensus.Shared.Tests/Classes/TestSensusCallbackScheduler.cs b/Sensus.Shared.Tests/Classes/TestSensusCallbackScheduler.cs
index 5d274089d..4965ea4e6 100644
--- a/Sensus.Shared.Tests/Classes/TestSensusCallbackScheduler.cs
+++ b/Sensus.Shared.Tests/Classes/TestSensusCallbackScheduler.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading.Tasks;
diff --git a/Sensus.Shared.Tests/Classes/TestSensusContext.cs b/Sensus.Shared.Tests/Classes/TestSensusContext.cs
index fa4e54011..8eec5f90f 100644
--- a/Sensus.Shared.Tests/Classes/TestSensusContext.cs
+++ b/Sensus.Shared.Tests/Classes/TestSensusContext.cs
@@ -1,47 +1,52 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-using System;
-using Sensus.Callbacks;
+using System;
+using Sensus.Callbacks;
using Sensus.Concurrent;
using Sensus.Context;
-using Sensus.Encryption;
+using Sensus.Encryption;
using Sensus.Notifications;
namespace Sensus.Tests.Classes
{
public class TestSensusContext : ISensusContext
- {
- public Platform Platform { get; set; }
- public IConcurrent MainThreadSynchronizer { get; set; }
- public IEncryption SymmetricEncryption { get; set; }
- public Notifier Notifier { get; set; }
- public CallbackScheduler CallbackScheduler { get; set; }
- public string ActivationId { get; set; }
- public string IamRegion { get; set; }
- public string IamAccessKey { get; set; }
- public string IamAccessKeySecret { get; set; }
- public PowerConnectionChangeListener PowerConnectionChangeListener { get; set; }
-
+ {
+ public Platform Platform { get; set; }
+ public IConcurrent MainThreadSynchronizer { get; set; }
+ public IEncryption SymmetricEncryption { get; set; }
+ public Notifier Notifier { get; set; }
+ public CallbackScheduler CallbackScheduler { get; set; }
+ public string ActivationId { get; set; }
+ public string IamRegion { get; set; }
+ public string IamAccessKey { get; set; }
+ public string IamAccessKeySecret { get; set; }
+ public PowerConnectionChangeListener PowerConnectionChangeListener { get; set; }
+
public TestSensusContext()
{
Platform = Platform.Test;
MainThreadSynchronizer = new LockConcurrent();
- SymmetricEncryption = new SymmetricEncryption("91091462A8D6FD3B4DB1D91C731070F10460D73AEE0377EDC2585C42F70A84A5");
- Notifier = new TestSensusNotifier();
- CallbackScheduler = new TestSensusCallbackScheduler();
- ActivationId = "asdfadsf";
+ SymmetricEncryption = new SymmetricEncryption("91091462A8D6FD3B4DB1D91C731070F10460D73AEE0377EDC2585C42F70A84A5");
+ Notifier = new TestSensusNotifier();
+ CallbackScheduler = new TestSensusCallbackScheduler();
+ ActivationId = "asdfadsf";
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Classes/TestSensusNotifier.cs b/Sensus.Shared.Tests/Classes/TestSensusNotifier.cs
index 4db1c8d8a..ceacad9bd 100644
--- a/Sensus.Shared.Tests/Classes/TestSensusNotifier.cs
+++ b/Sensus.Shared.Tests/Classes/TestSensusNotifier.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus.Notifications;
using System.Threading.Tasks;
diff --git a/Sensus.Shared.Tests/Classes/TestSensusServiceHelper.cs b/Sensus.Shared.Tests/Classes/TestSensusServiceHelper.cs
index 40010611c..6a50e547a 100644
--- a/Sensus.Shared.Tests/Classes/TestSensusServiceHelper.cs
+++ b/Sensus.Shared.Tests/Classes/TestSensusServiceHelper.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading.Tasks;
diff --git a/Sensus.Shared.Tests/Classes/XUnitResultCounter.cs b/Sensus.Shared.Tests/Classes/XUnitResultCounter.cs
index 2d670d0ca..9cad53537 100644
--- a/Sensus.Shared.Tests/Classes/XUnitResultCounter.cs
+++ b/Sensus.Shared.Tests/Classes/XUnitResultCounter.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
@@ -59,4 +64,4 @@ public void RecordResult(TestResultViewModel result)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Anonymization/Anonymizers/LongitudeOffsetGpsAnonymizerTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Anonymization/Anonymizers/LongitudeOffsetGpsAnonymizerTests.cs
index ae9eb4f84..b8edfd379 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Anonymization/Anonymizers/LongitudeOffsetGpsAnonymizerTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Anonymization/Anonymizers/LongitudeOffsetGpsAnonymizerTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Xunit;
using Sensus.Anonymization.Anonymizers;
@@ -115,4 +120,4 @@ public async Task RandomDeviceIdOffsetsEqualTest()
Assert.Equal(randomOffset1, randomOffset2, 5);
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Concurrent/ConcurrentObservableCollectionTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Concurrent/ConcurrentObservableCollectionTests.cs
index 68130acb3..ac877fa14 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Concurrent/ConcurrentObservableCollectionTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Concurrent/ConcurrentObservableCollectionTests.cs
@@ -1,206 +1,211 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System;
-using System.Threading.Tasks;
-using System.Collections.Generic;
-using Xunit;
-using Sensus.Concurrent;
-
-namespace Sensus.Tests.Concurrent
-{
-
- public class ConcurrentObservableCollectionTests
- {
- private const int DelayTime = 2;
- private readonly IConcurrent Concurrent;
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System;
+using System.Threading.Tasks;
+using System.Collections.Generic;
+using Xunit;
+using Sensus.Concurrent;
+
+namespace Sensus.Tests.Concurrent
+{
+
+ public class ConcurrentObservableCollectionTests
+ {
+ private const int DelayTime = 2;
+ private readonly IConcurrent Concurrent;
+
public ConcurrentObservableCollectionTests()
- {
- Concurrent = new LockConcurrent();
- }
-
- [Fact]
- public void DelayIsLongEnough()
- {
- var test = new List { 1, 2, 3 };
-
- var task1 = Task.Run(() =>
- {
- foreach (var i in test)
- {
- Task.Delay(DelayTime).Wait();
- }
- });
-
- var task2 = Task.Run(() =>
- {
- test.Insert(0, 4);
- Task.Delay(DelayTime).Wait();
- test.Insert(0, 5);
- });
-
- Assert.Throws(() => Task.WaitAll(task1, task2));
- }
-
- [Fact]
- public void AddIsThreadSafe()
- {
- var test = new ConcurrentObservableCollection (Concurrent) { 1, 2, 3 };
-
- var task1 = Task.Run(() =>
- {
- foreach (var i in test)
- {
- Task.Delay(DelayTime).Wait();
- }
- });
-
- var task2 = Task.Run(() =>
- {
- test.Add(4);
- Task.Delay(DelayTime).Wait();
- test.Add(5);
- });
-
- Task.WaitAll(task1, task2);
- }
-
- [Fact]
- public void InsertIsThreadSafe()
- {
- var test = new ConcurrentObservableCollection(Concurrent) { 1, 2, 3 };
-
- var task1 = Task.Run(() =>
- {
- foreach (var i in test)
- {
- Task.Delay(DelayTime).Wait();
- }
- });
-
- var task2 = Task.Run(() =>
- {
- test.Insert(0, 4);
- Task.Delay(DelayTime).Wait();
- test.Insert(0, 5);
- });
-
- Task.WaitAll(task1, task2);
- }
-
- [Fact]
- public void RemoveIsThreadSafe()
- {
- var test = new ConcurrentObservableCollection(Concurrent) { 1, 2, 3 };
-
- var task1 = Task.Run(() =>
- {
- foreach (var i in test)
- {
- Task.Delay(DelayTime).Wait();
- }
- });
-
- var task2 = Task.Run(() =>
- {
- test.Remove(2);
- Task.Delay(DelayTime).Wait();
- test.Remove(1);
- });
-
- Task.WaitAll(task1, task2);
- }
-
- [Fact]
- public void ClearIsThreadSafe()
- {
- var test = new ConcurrentObservableCollection(Concurrent) { 1, 2, 3 };
-
- var task1 = Task.Run(() =>
- {
- foreach (var i in test)
- {
- Task.Delay(DelayTime).Wait();
- }
- });
-
- var task2 = Task.Run(() =>
- {
- Task.Delay(DelayTime).Wait();
- test.Clear();
- });
-
- Task.WaitAll(task1, task2);
- }
-
- [Fact]
- public void ContainsIsThreadSafe()
- {
- var test = new ConcurrentObservableCollection(Concurrent) { 1, 2, 3 };
-
- var task1 = Task.Run(() =>
- {
- for (var i = 0; i < 10; i++)
- {
- test.Contains(2);
- Task.Delay(DelayTime).Wait();
- test.Contains(4);
- }
- });
-
- var task2 = Task.Run(() =>
- {
- for (var i = 0; i < 10; i++)
- {
- test.Add(4);
- Task.Delay(DelayTime).Wait();
- test.Add(5);
- }
- });
-
- Task.WaitAll(task1, task2);
- }
-
- [Fact]
- public void CopyToIsThreadSafe()
- {
- var test = new ConcurrentObservableCollection(Concurrent) { 1, 2, 3 };
- var out1 = new int[5];
- var out2 = new int[5];
-
- var task1 = Task.Run(() =>
- {
- for (var i = 0; i < 10; i++)
- {
- test.CopyTo(out1, 0);
- Task.Delay(DelayTime).Wait();
- test.CopyTo(out2, 0);
- }
- });
-
- var task2 = Task.Run(() =>
- {
- for (var i = 0; i < 10; i++)
- {
- test.Add(4);
- Task.Delay(DelayTime).Wait();
- test.Remove(4);
- }
- });
-
- Task.WaitAll(task1, task2);
- }
- }
-}
\ No newline at end of file
+ {
+ Concurrent = new LockConcurrent();
+ }
+
+ [Fact]
+ public void DelayIsLongEnough()
+ {
+ var test = new List { 1, 2, 3 };
+
+ var task1 = Task.Run(() =>
+ {
+ foreach (var i in test)
+ {
+ Task.Delay(DelayTime).Wait();
+ }
+ });
+
+ var task2 = Task.Run(() =>
+ {
+ test.Insert(0, 4);
+ Task.Delay(DelayTime).Wait();
+ test.Insert(0, 5);
+ });
+
+ Assert.Throws(() => Task.WaitAll(task1, task2));
+ }
+
+ [Fact]
+ public void AddIsThreadSafe()
+ {
+ var test = new ConcurrentObservableCollection (Concurrent) { 1, 2, 3 };
+
+ var task1 = Task.Run(() =>
+ {
+ foreach (var i in test)
+ {
+ Task.Delay(DelayTime).Wait();
+ }
+ });
+
+ var task2 = Task.Run(() =>
+ {
+ test.Add(4);
+ Task.Delay(DelayTime).Wait();
+ test.Add(5);
+ });
+
+ Task.WaitAll(task1, task2);
+ }
+
+ [Fact]
+ public void InsertIsThreadSafe()
+ {
+ var test = new ConcurrentObservableCollection(Concurrent) { 1, 2, 3 };
+
+ var task1 = Task.Run(() =>
+ {
+ foreach (var i in test)
+ {
+ Task.Delay(DelayTime).Wait();
+ }
+ });
+
+ var task2 = Task.Run(() =>
+ {
+ test.Insert(0, 4);
+ Task.Delay(DelayTime).Wait();
+ test.Insert(0, 5);
+ });
+
+ Task.WaitAll(task1, task2);
+ }
+
+ [Fact]
+ public void RemoveIsThreadSafe()
+ {
+ var test = new ConcurrentObservableCollection(Concurrent) { 1, 2, 3 };
+
+ var task1 = Task.Run(() =>
+ {
+ foreach (var i in test)
+ {
+ Task.Delay(DelayTime).Wait();
+ }
+ });
+
+ var task2 = Task.Run(() =>
+ {
+ test.Remove(2);
+ Task.Delay(DelayTime).Wait();
+ test.Remove(1);
+ });
+
+ Task.WaitAll(task1, task2);
+ }
+
+ [Fact]
+ public void ClearIsThreadSafe()
+ {
+ var test = new ConcurrentObservableCollection(Concurrent) { 1, 2, 3 };
+
+ var task1 = Task.Run(() =>
+ {
+ foreach (var i in test)
+ {
+ Task.Delay(DelayTime).Wait();
+ }
+ });
+
+ var task2 = Task.Run(() =>
+ {
+ Task.Delay(DelayTime).Wait();
+ test.Clear();
+ });
+
+ Task.WaitAll(task1, task2);
+ }
+
+ [Fact]
+ public void ContainsIsThreadSafe()
+ {
+ var test = new ConcurrentObservableCollection(Concurrent) { 1, 2, 3 };
+
+ var task1 = Task.Run(() =>
+ {
+ for (var i = 0; i < 10; i++)
+ {
+ test.Contains(2);
+ Task.Delay(DelayTime).Wait();
+ test.Contains(4);
+ }
+ });
+
+ var task2 = Task.Run(() =>
+ {
+ for (var i = 0; i < 10; i++)
+ {
+ test.Add(4);
+ Task.Delay(DelayTime).Wait();
+ test.Add(5);
+ }
+ });
+
+ Task.WaitAll(task1, task2);
+ }
+
+ [Fact]
+ public void CopyToIsThreadSafe()
+ {
+ var test = new ConcurrentObservableCollection(Concurrent) { 1, 2, 3 };
+ var out1 = new int[5];
+ var out2 = new int[5];
+
+ var task1 = Task.Run(() =>
+ {
+ for (var i = 0; i < 10; i++)
+ {
+ test.CopyTo(out1, 0);
+ Task.Delay(DelayTime).Wait();
+ test.CopyTo(out2, 0);
+ }
+ });
+
+ var task2 = Task.Run(() =>
+ {
+ for (var i = 0; i < 10; i++)
+ {
+ test.Add(4);
+ Task.Delay(DelayTime).Wait();
+ test.Remove(4);
+ }
+ });
+
+ Task.WaitAll(task1, task2);
+ }
+ }
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Concurrent/ConcurrentTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Concurrent/ConcurrentTests.cs
index 106cea367..d3c8c7ed6 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Concurrent/ConcurrentTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Concurrent/ConcurrentTests.cs
@@ -1,190 +1,195 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System;
-using System.Threading.Tasks;
-using System.Collections.Generic;
-using Xunit;
-using Sensus.Concurrent;
-
-namespace Sensus.Tests.Concurrent
-{
- public abstract class ConcurrentTests
- {
- #region Fields
- private const int DelayTime = 2;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System;
+using System.Threading.Tasks;
+using System.Collections.Generic;
+using Xunit;
+using Sensus.Concurrent;
+
+namespace Sensus.Tests.Concurrent
+{
+ public abstract class ConcurrentTests
+ {
+ #region Fields
+ private const int DelayTime = 2;
private readonly IConcurrent _concurrent;
- #endregion
+ #endregion
+
+ #region Constructors
+ protected ConcurrentTests(IConcurrent concurrent)
+ {
+ _concurrent = concurrent;
+ }
+ #endregion
- #region Constructors
- protected ConcurrentTests(IConcurrent concurrent)
- {
- _concurrent = concurrent;
+ [Fact]
+ public void DelayIsLongEnough()
+ {
+ var test = new List { 1, 2, 3 };
+
+ var task1 = Task.Run(() =>
+ {
+ foreach (var i in test)
+ {
+ Task.Delay(DelayTime).Wait();
+ }
+ });
+
+ var task2 = Task.Run(() =>
+ {
+ test.Add(4);
+ Task.Delay(DelayTime).Wait();
+ test.Add(5);
+ });
+
+ Assert.Throws(() => Task.WaitAll(task1, task2));
+ }
+
+ [Fact]
+ public void ExecuteThreadSafeActionThrowsNoException()
+ {
+ var test = new List { 1, 2, 3 };
+
+ _concurrent.ExecuteThreadSafe(() =>
+ {
+ test.Add(4);
+
+ foreach (var i in test)
+ {
+ Task.Delay(DelayTime).Wait();
+ }
+
+ test.Add(5);
+ });
}
- #endregion
-
- [Fact]
- public void DelayIsLongEnough()
- {
- var test = new List { 1, 2, 3 };
-
- var task1 = Task.Run(() =>
- {
- foreach (var i in test)
- {
- Task.Delay(DelayTime).Wait();
- }
- });
-
- var task2 = Task.Run(() =>
- {
- test.Add(4);
- Task.Delay(DelayTime).Wait();
- test.Add(5);
- });
-
- Assert.Throws(() => Task.WaitAll(task1, task2));
- }
-
- [Fact]
- public void ExecuteThreadSafeActionThrowsNoException()
- {
- var test = new List { 1, 2, 3 };
-
- _concurrent.ExecuteThreadSafe(() =>
- {
- test.Add(4);
-
- foreach (var i in test)
- {
- Task.Delay(DelayTime).Wait();
- }
-
- test.Add(5);
+
+ [Fact]
+ public void ExecuteThreadSafeFuncThrowsNoException()
+ {
+ var test = new List { 1, 2, 3 };
+
+ _concurrent.ExecuteThreadSafe(() =>
+ {
+ test.Add(4);
+
+ foreach (var i in test)
+ {
+ Task.Delay(DelayTime).Wait();
+ }
+
+ test.Add(5);
+
+ return test;
});
- }
-
- [Fact]
- public void ExecuteThreadSafeFuncThrowsNoException()
- {
- var test = new List { 1, 2, 3 };
-
- _concurrent.ExecuteThreadSafe(() =>
- {
- test.Add(4);
-
- foreach (var i in test)
- {
- Task.Delay(DelayTime).Wait();
- }
-
- test.Add(5);
-
- return test;
- });
}
- [Fact]
- public void ExecuteThreadSafeActionIsThreadSafe()
- {
- var test = new List { 1, 2, 3 };
-
- var task1 = Task.Run(() =>
- {
- _concurrent.ExecuteThreadSafe(() =>
- {
+ [Fact]
+ public void ExecuteThreadSafeActionIsThreadSafe()
+ {
+ var test = new List { 1, 2, 3 };
+
+ var task1 = Task.Run(() =>
+ {
+ _concurrent.ExecuteThreadSafe(() =>
+ {
foreach (var i in test)
{
Task.Delay(DelayTime).Wait();
- }
+ }
});
- });
-
- var task2 = Task.Run(() =>
- {
- _concurrent.ExecuteThreadSafe(() =>
+ });
+
+ var task2 = Task.Run(() =>
+ {
+ _concurrent.ExecuteThreadSafe(() =>
{
test.Add(4);
Task.Delay(DelayTime).Wait();
- test.Add(5);
+ test.Add(5);
+ });
+ });
+
+ Task.WaitAll(task1, task2);
+ }
+
+ [Fact]
+ public void ExecuteThreadSafeFuncIsThreadSafe()
+ {
+ var test = new List { 1, 2, 3 };
+
+ var task1 = Task.Run(() =>
+ {
+ var output = _concurrent.ExecuteThreadSafe(() =>
+ {
+ foreach (var i in test)
+ {
+ Task.Delay(DelayTime).Wait();
+ }
+
+ return test;
});
- });
-
- Task.WaitAll(task1, task2);
- }
-
- [Fact]
- public void ExecuteThreadSafeFuncIsThreadSafe()
- {
- var test = new List { 1, 2, 3 };
-
- var task1 = Task.Run(() =>
- {
- var output = _concurrent.ExecuteThreadSafe(() =>
- {
- foreach (var i in test)
- {
- Task.Delay(DelayTime).Wait();
- }
-
- return test;
- });
-
- Assert.Same(output, test);
- });
-
- var task2 = Task.Run(() =>
- {
- var output = _concurrent.ExecuteThreadSafe(() =>
+
+ Assert.Same(output, test);
+ });
+
+ var task2 = Task.Run(() =>
+ {
+ var output = _concurrent.ExecuteThreadSafe(() =>
{
test.Add(4);
Task.Delay(DelayTime).Wait();
- test.Add(5);
-
- return test;
+ test.Add(5);
+
+ return test;
});
Assert.Same(output, test);
- });
-
- Task.WaitAll(task1, task2);
+ });
+
+ Task.WaitAll(task1, task2);
}
- [Fact]
- public void ExecuteThreadSafeActionIsSynchronous()
- {
- var test = new List { 1, 2, 3 };
-
- _concurrent.ExecuteThreadSafe(() =>
+ [Fact]
+ public void ExecuteThreadSafeActionIsSynchronous()
+ {
+ var test = new List { 1, 2, 3 };
+
+ _concurrent.ExecuteThreadSafe(() =>
{
- foreach (var i in test)
- {
- Task.Delay(DelayTime).Wait();
+ foreach (var i in test)
+ {
+ Task.Delay(DelayTime).Wait();
}
});
- test.Add(4);
- Task.Delay(DelayTime).Wait();
- test.Add(5);
-
- Assert.True(test.Contains(4));
- Assert.True(test.Contains(5));
+ test.Add(4);
+ Task.Delay(DelayTime).Wait();
+ test.Add(5);
+
+ Assert.True(test.Contains(4));
+ Assert.True(test.Contains(5));
}
- [Fact]
- public void ExecuteThreadSafeFuncIsSynchronous()
- {
+ [Fact]
+ public void ExecuteThreadSafeFuncIsSynchronous()
+ {
var test = new List { 1, 2, 3 };
_concurrent.ExecuteThreadSafe(() =>
@@ -197,17 +202,17 @@ public void ExecuteThreadSafeFuncIsSynchronous()
return test;
});
- test.Add(4);
- Task.Delay(DelayTime).Wait();
- test.Add(5);
-
- Assert.True(test.Contains(4));
- Assert.True(test.Contains(5));
- }
-
- [Fact]
- public void ExecuteThreadSafeFuncReturnsCorrectly()
- {
+ test.Add(4);
+ Task.Delay(DelayTime).Wait();
+ test.Add(5);
+
+ Assert.True(test.Contains(4));
+ Assert.True(test.Contains(5));
+ }
+
+ [Fact]
+ public void ExecuteThreadSafeFuncReturnsCorrectly()
+ {
var test = new List { 1, 2, 3 };
var output = _concurrent.ExecuteThreadSafe(() =>
@@ -218,85 +223,85 @@ public void ExecuteThreadSafeFuncReturnsCorrectly()
}
return test;
- });
-
- Assert.Same(output, test);
- }
-
- [Fact]
- public void InnerExecuteThreadSafeActionNoDeadlock()
- {
- var test = new List { 1, 2, 3 };
-
+ });
+
+ Assert.Same(output, test);
+ }
+
+ [Fact]
+ public void InnerExecuteThreadSafeActionNoDeadlock()
+ {
+ var test = new List { 1, 2, 3 };
+
_concurrent.ExecuteThreadSafe(() =>
{
_concurrent.ExecuteThreadSafe(() =>
{
- for (var i = 4; i <= 6; i++)
- {
- test.Add(i);
+ for (var i = 4; i <= 6; i++)
+ {
+ test.Add(i);
Task.Delay(DelayTime).Wait();
}
});
});
Assert.Equal(6, test.Count);
- }
-
- [Fact]
- public void InnerExecuteThreadSafeFuncNoDeadlock()
- {
+ }
+
+ [Fact]
+ public void InnerExecuteThreadSafeFuncNoDeadlock()
+ {
var test = new List { 1, 2, 3 };
_concurrent.ExecuteThreadSafe(() =>
{
return _concurrent.ExecuteThreadSafe(() =>
{
- for (var i = 4; i <= 6; i++)
- {
- test.Add(i);
+ for (var i = 4; i <= 6; i++)
+ {
+ test.Add(i);
Task.Delay(DelayTime).Wait();
- }
-
+ }
+
return test;
});
});
//we check test because in the case of a deadlock I'm not sure what output will be returned...
- Assert.Equal(6, test.Count);
- }
-
- [Fact]
- public void ExecuteThreadSafeActionCatchesExceptionFromSameThread()
- {
- Assert.Throws(typeof(Exception), () =>
- {
- _concurrent.ExecuteThreadSafe(() =>
- {
- _concurrent.ExecuteThreadSafe(() =>
- {
- throw new Exception();
- });
- });
- });
- }
-
- [Fact]
- public void ExecuteThreadSafeFuncCatchesExceptionFromSameThread()
- {
- Assert.Throws(typeof(Exception), () =>
- {
- _concurrent.ExecuteThreadSafe(() =>
- {
- int x = _concurrent.ExecuteThreadSafe(() =>
- {
- throw new Exception();
-#pragma warning disable CS0162 // Unreachable code detected
- return 1; // required to make this a function rather than an action
-#pragma warning restore CS0162 // Unreachable code detected
- });
- });
- });
- }
- }
-}
\ No newline at end of file
+ Assert.Equal(6, test.Count);
+ }
+
+ [Fact]
+ public void ExecuteThreadSafeActionCatchesExceptionFromSameThread()
+ {
+ Assert.Throws(typeof(Exception), () =>
+ {
+ _concurrent.ExecuteThreadSafe(() =>
+ {
+ _concurrent.ExecuteThreadSafe(() =>
+ {
+ throw new Exception();
+ });
+ });
+ });
+ }
+
+ [Fact]
+ public void ExecuteThreadSafeFuncCatchesExceptionFromSameThread()
+ {
+ Assert.Throws(typeof(Exception), () =>
+ {
+ _concurrent.ExecuteThreadSafe(() =>
+ {
+ int x = _concurrent.ExecuteThreadSafe(() =>
+ {
+ throw new Exception();
+#pragma warning disable CS0162 // Unreachable code detected
+ return 1; // required to make this a function rather than an action
+#pragma warning restore CS0162 // Unreachable code detected
+ });
+ });
+ });
+ }
+ }
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Concurrent/LockConcurrentTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Concurrent/LockConcurrentTests.cs
index 7284aab9c..4fd982611 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Concurrent/LockConcurrentTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Concurrent/LockConcurrentTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Xunit;
using Sensus.Concurrent;
@@ -25,4 +30,4 @@ public LockConcurrentTests() : base(new LockConcurrent())
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/DataStores/CompressionTests.cs b/Sensus.Shared.Tests/Sensus.Shared/DataStores/CompressionTests.cs
index 4484f9a2c..fe5ba5a75 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/DataStores/CompressionTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/DataStores/CompressionTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.IO;
diff --git a/Sensus.Shared.Tests/Sensus.Shared/DataStores/DataStoreTests.cs b/Sensus.Shared.Tests/Sensus.Shared/DataStores/DataStoreTests.cs
index ca9f9a769..19dfe25a0 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/DataStores/DataStoreTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/DataStores/DataStoreTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
diff --git a/Sensus.Shared.Tests/Sensus.Shared/DataStores/Local/FileLocalDataStoreTests.cs b/Sensus.Shared.Tests/Sensus.Shared/DataStores/Local/FileLocalDataStoreTests.cs
index d21354a43..4859d25ca 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/DataStores/Local/FileLocalDataStoreTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/DataStores/Local/FileLocalDataStoreTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
@@ -371,4 +376,4 @@ private void WriteData(List data, FileLocalDataStore localDataStore, Acti
}
#endregion
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/DatumTests.cs b/Sensus.Shared.Tests/Sensus.Shared/DatumTests.cs
index d6dac489d..b6672c967 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/DatumTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/DatumTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Xunit;
@@ -85,4 +90,4 @@ public async Task SerializeDeserializeWithEnumTest()
Assert.Equal(datum.State, deserializedDatum.State);
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Dispose/DisposableTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Dispose/DisposableTests.cs
index fa0c61243..d220bd966 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Dispose/DisposableTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Dispose/DisposableTests.cs
@@ -1,21 +1,26 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System;
-using Xunit;
-using Sensus.Dispose;
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System;
+using Xunit;
+using Sensus.Dispose;
+
namespace Sensus.Tests.Dispose
{
@@ -54,52 +59,52 @@ protected override void Dispose(bool disposing)
[Fact]
public void BadPatternThrowsException()
- {
- using (var badPattern = new BadPattern())
- {
+ {
+ using (var badPattern = new BadPattern())
+ {
Assert.Throws(typeof(InvalidOperationException), (Action)badPattern.Dispose);
- badPattern.FixDispose = true;
- }
+ badPattern.FixDispose = true;
+ }
}
[Fact]
public void GoodPatternThrowsNoException()
- {
- using (var goodPattern = new GoodPattern())
- {
- goodPattern.Dispose();
- }
+ {
+ using (var goodPattern = new GoodPattern())
+ {
+ goodPattern.Dispose();
+ }
}
[Fact]
public void GoodPatternMultiDisposeThrowsNoException()
- {
- using (var goodPattern = new GoodPattern())
- {
- goodPattern.Dispose();
- goodPattern.Dispose();
- }
+ {
+ using (var goodPattern = new GoodPattern())
+ {
+ goodPattern.Dispose();
+ goodPattern.Dispose();
+ }
}
[Fact]
public void GoodPatternDisposeCheckPassesBeforeDispose()
- {
- using (var goodPattern = new GoodPattern())
- {
- goodPattern.DisposeCheck();
- }
+ {
+ using (var goodPattern = new GoodPattern())
+ {
+ goodPattern.DisposeCheck();
+ }
}
[Fact]
public void GoodPatternDisposeCheckFailsAfterDispose()
- {
- using (var goodPattern = new GoodPattern())
- {
- goodPattern.Dispose();
-
- Assert.Throws(typeof(ObjectDisposedException), (Action)goodPattern.DisposeCheck);
- }
+ {
+ using (var goodPattern = new GoodPattern())
+ {
+ goodPattern.Dispose();
+
+ Assert.Throws(typeof(ObjectDisposedException), (Action)goodPattern.DisposeCheck);
+ }
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Encryption/AsymmetricEncryptionTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Encryption/AsymmetricEncryptionTests.cs
index 67328e726..47f1ce28d 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Encryption/AsymmetricEncryptionTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Encryption/AsymmetricEncryptionTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Xunit;
using Sensus.Encryption;
@@ -118,4 +123,4 @@ public void SymmetricEncryptionEqualsTest()
Assert.Equal(message, decryptedMessage);
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Encryption/SymmetricEncryptionTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Encryption/SymmetricEncryptionTests.cs
index 3bf7579e3..cdd9976a7 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Encryption/SymmetricEncryptionTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Encryption/SymmetricEncryptionTests.cs
@@ -1,20 +1,25 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Xunit;
-using Sensus.Encryption;
-using System.Security.Cryptography;
+using Sensus.Encryption;
+using System.Security.Cryptography;
using System;
namespace Sensus.Tests.Encryption
@@ -25,19 +30,19 @@ public class SymmetricEncryptionTests
[Fact]
public void ShortEncryptionKeyTest()
{
- var encryption = new SymmetricEncryption("123123");
-
+ var encryption = new SymmetricEncryption("123123");
+
Assert.Throws(typeof(CryptographicException), () => { encryption.Encrypt("A"); });
- }
-
- [Fact]
- public void OddLengthEncryptionKeyTest()
- {
- Assert.Throws(typeof(ArgumentOutOfRangeException), () =>
- {
- var encryption = new SymmetricEncryption("12312");
- encryption.Encrypt("A");
- });
+ }
+
+ [Fact]
+ public void OddLengthEncryptionKeyTest()
+ {
+ Assert.Throws(typeof(ArgumentOutOfRangeException), () =>
+ {
+ var encryption = new SymmetricEncryption("12312");
+ encryption.Encrypt("A");
+ });
}
[Fact]
@@ -48,4 +53,4 @@ public void GoodEncryptionKeyTest()
Assert.Equal("asl3j3lkfjwlkj3lwk3jflwk3j", encryption.DecryptToString(encryption.Encrypt("asl3j3lkfjwlkj3lwk3jflwk3j")));
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Extensions/DateTimeExtensionsTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Extensions/DateTimeExtensionsTests.cs
index ebc71d1cd..31c728e3a 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Extensions/DateTimeExtensionsTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Extensions/DateTimeExtensionsTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Xunit;
@@ -101,4 +106,4 @@ public void MinNullableSecond()
Assert.Equal(date1, date2.Min(date1));
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Extensions/NumericExtensionsTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Extensions/NumericExtensionsTests.cs
index 94c3c2f02..9c9c00cd9 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Extensions/NumericExtensionsTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Extensions/NumericExtensionsTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Xunit;
@@ -69,4 +74,4 @@ public void ZeroDenominatorTest()
Assert.Equal(Convert.ToString(7.RoundToWholePercentageOf(0, 1)), "");
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Probes/DataRateCalculatorTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Probes/DataRateCalculatorTests.cs
index b0b5d104a..c149b1bbe 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Probes/DataRateCalculatorTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Probes/DataRateCalculatorTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Xunit;
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Probes/ProbeTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Probes/ProbeTests.cs
index 7d592ddde..8d6029343 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Probes/ProbeTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Probes/ProbeTests.cs
@@ -1,39 +1,44 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
using Sensus.Context;
-using Sensus.Probes;
-using Xunit;
-
-namespace Sensus.Tests.Probes
-{
- public class ProbeTests
- {
- ///
- /// Ensure that we can construct all probes using the constructorless parameter and without
- /// the presence of the service helper. This is necessary because, upon deserialization of
- /// the service helper, the service helper singleton will be null and unavailable for
- /// referencing from within the probe constructors.
- ///
- [Fact]
- public void ProbeParameterlessConstructorTest()
- {
- SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
- {
- SensusServiceHelper.ClearSingleton();
- Assert.True(Probe.GetAll().Count > 0);
- });
- }
- }
-}
\ No newline at end of file
+using Sensus.Probes;
+using Xunit;
+
+namespace Sensus.Tests.Probes
+{
+ public class ProbeTests
+ {
+ ///
+ /// Ensure that we can construct all probes using the constructorless parameter and without
+ /// the presence of the service helper. This is necessary because, upon deserialization of
+ /// the service helper, the service helper singleton will be null and unavailable for
+ /// referencing from within the probe constructors.
+ ///
+ [Fact]
+ public void ProbeParameterlessConstructorTest()
+ {
+ SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
+ {
+ SensusServiceHelper.ClearSingleton();
+ Assert.True(Probe.GetAll().Count > 0);
+ });
+ }
+ }
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Probes/User/Scripts/ScheduleTriggerTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Probes/User/Scripts/ScheduleTriggerTests.cs
index daf862b65..436bf92c7 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Probes/User/Scripts/ScheduleTriggerTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Probes/User/Scripts/ScheduleTriggerTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Linq;
@@ -26,8 +31,8 @@ public class ScheduleTriggerTests
[Fact]
public void Deserialize1PointTest()
{
- var schedule = new ScheduleTrigger { WindowsString = "10:00" };
-
+ var schedule = new ScheduleTrigger { WindowsString = "10:00" };
+
Assert.Equal(1, schedule.WindowCount);
Assert.Equal("10:00", schedule.WindowsString);
}
@@ -66,58 +71,58 @@ public void Deserialize1Point1WindowSpacesTest()
Assert.Equal(2, schedule.WindowCount);
Assert.Equal("10:00, 10:10-10:20", schedule.WindowsString);
- }
-
- [Fact]
- public void DowDeserialize1PointTest()
- {
- var schedule = new ScheduleTrigger { WindowsString = "Su-10:00" };
-
- Assert.Equal(1, schedule.WindowCount);
- Assert.Equal("Su-10:00", schedule.WindowsString);
- }
-
- [Fact]
- public void DowDeserialize1WindowTest()
- {
- var schedule = new ScheduleTrigger { WindowsString = "Mo-10:00-10:30" };
-
- Assert.Equal(1, schedule.WindowCount);
- Assert.Equal("Mo-10:00-10:30", schedule.WindowsString);
- }
-
- [Fact]
- public void DowDeserialize1PointTrailingCommaTest()
- {
- var schedule = new ScheduleTrigger { WindowsString = "Tu-10:00," };
-
- Assert.Equal(1, schedule.WindowCount);
- Assert.Equal("Tu-10:00", schedule.WindowsString);
- }
-
- [Fact]
- public void DowDeserialize1Point1WindowTest()
- {
- var schedule = new ScheduleTrigger { WindowsString = "We-10:00,10:10-10:20" };
-
- Assert.Equal(2, schedule.WindowCount);
- Assert.Equal("We-10:00, 10:10-10:20", schedule.WindowsString);
- }
-
- [Fact]
- public void DowDeserialize1Point1WindowSpacesTest()
- {
- var schedule = new ScheduleTrigger { WindowsString = "10:00, Th-10:10-10:20" };
-
- Assert.Equal(2, schedule.WindowCount);
- Assert.Equal("10:00, Th-10:10-10:20", schedule.WindowsString);
+ }
+
+ [Fact]
+ public void DowDeserialize1PointTest()
+ {
+ var schedule = new ScheduleTrigger { WindowsString = "Su-10:00" };
+
+ Assert.Equal(1, schedule.WindowCount);
+ Assert.Equal("Su-10:00", schedule.WindowsString);
+ }
+
+ [Fact]
+ public void DowDeserialize1WindowTest()
+ {
+ var schedule = new ScheduleTrigger { WindowsString = "Mo-10:00-10:30" };
+
+ Assert.Equal(1, schedule.WindowCount);
+ Assert.Equal("Mo-10:00-10:30", schedule.WindowsString);
+ }
+
+ [Fact]
+ public void DowDeserialize1PointTrailingCommaTest()
+ {
+ var schedule = new ScheduleTrigger { WindowsString = "Tu-10:00," };
+
+ Assert.Equal(1, schedule.WindowCount);
+ Assert.Equal("Tu-10:00", schedule.WindowsString);
+ }
+
+ [Fact]
+ public void DowDeserialize1Point1WindowTest()
+ {
+ var schedule = new ScheduleTrigger { WindowsString = "We-10:00,10:10-10:20" };
+
+ Assert.Equal(2, schedule.WindowCount);
+ Assert.Equal("We-10:00, 10:10-10:20", schedule.WindowsString);
+ }
+
+ [Fact]
+ public void DowDeserialize1Point1WindowSpacesTest()
+ {
+ var schedule = new ScheduleTrigger { WindowsString = "10:00, Th-10:10-10:20" };
+
+ Assert.Equal(2, schedule.WindowCount);
+ Assert.Equal("10:00, Th-10:10-10:20", schedule.WindowsString);
}
[Fact]
public void SchedulesPullsOnlyTenDays()
{
- var schedule = new ScheduleTrigger { WindowsString = "10:00" };
-
+ var schedule = new ScheduleTrigger { WindowsString = "10:00" };
+
var triggerTimeCount = schedule.GetTriggerTimes(DateTime.Now).Count();
Assert.Equal(10, triggerTimeCount);
@@ -138,4 +143,4 @@ public void SchedulesAllFutureNoExpirationsTest()
Assert.Equal(null, triggerTimes[5].Expiration);
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/Probes/User/Scripts/ScriptTests.cs b/Sensus.Shared.Tests/Sensus.Shared/Probes/User/Scripts/ScriptTests.cs
index 2598acf84..6b1409f0c 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/Probes/User/Scripts/ScriptTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/Probes/User/Scripts/ScriptTests.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Xunit;
using Sensus.Probes.User.Scripts;
diff --git a/Sensus.Shared.Tests/Sensus.Shared/ProtocolTests.cs b/Sensus.Shared.Tests/Sensus.Shared/ProtocolTests.cs
index 9fff120e3..620f6da28 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/ProtocolTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/ProtocolTests.cs
@@ -1,51 +1,56 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
-using Xunit;
-using System.Collections.Generic;
+using Xunit;
+using System.Collections.Generic;
using System.Threading.Tasks;
-using Sensus.Tests.Classes;
-using Sensus.Context;
-
+using Sensus.Tests.Classes;
+using Sensus.Context;
+
namespace Sensus.Tests
{
public class ProtocolTests
{
- #region Fields
+ #region Fields
private JsonSerializerSettings _jsonSerializerSettings;
- #endregion
+ #endregion
#region SetUp
- public ProtocolTests()
- {
- _jsonSerializerSettings = SensusServiceHelper.JSON_SERIALIZER_SETTINGS;
-
- // we don't want to quietly handle errors when testing.
- _jsonSerializerSettings.Error = null;
-
- SensusServiceHelper.ClearSingleton();
+ public ProtocolTests()
+ {
+ _jsonSerializerSettings = SensusServiceHelper.JSON_SERIALIZER_SETTINGS;
+
+ // we don't want to quietly handle errors when testing.
+ _jsonSerializerSettings.Error = null;
+
+ SensusServiceHelper.ClearSingleton();
}
#endregion
[Fact]
public async Task ProtocolSerializeDeserializeTest()
- {
- SensusServiceHelper.Initialize(() => new TestSensusServiceHelper());
-
+ {
+ SensusServiceHelper.Initialize(() => new TestSensusServiceHelper());
+
var protocol1 = await Protocol.CreateAsync("abc");
protocol1.ContactEmail = "ContactEmail";
protocol1.ContinueIndefinitely = true;
@@ -55,13 +60,13 @@ public async Task ProtocolSerializeDeserializeTest()
protocol1.GpsDesiredAccuracyMeters = 0.1f;
protocol1.GpsMinDistanceDelayMeters = 0.2f;
protocol1.GpsMinTimeDelayMS = 10;
- protocol1.Groupable = true;
+ protocol1.Groupable = true;
protocol1.VariableValueUiProperty = new List(new string[] { "var1: val1", "var1:", "var1:val2", "var2", "var2:" });
-
- Protocol protocol2 = null;
- SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
- {
- protocol2 = JsonConvert.DeserializeObject(JsonConvert.SerializeObject(protocol1, _jsonSerializerSettings), _jsonSerializerSettings);
+
+ Protocol protocol2 = null;
+ SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
+ {
+ protocol2 = JsonConvert.DeserializeObject(JsonConvert.SerializeObject(protocol1, _jsonSerializerSettings), _jsonSerializerSettings);
});
Assert.Equal(protocol1.Name, protocol2.Name);
@@ -73,9 +78,9 @@ public async Task ProtocolSerializeDeserializeTest()
Assert.Equal(protocol1.GpsDesiredAccuracyMeters, protocol2.GpsDesiredAccuracyMeters);
Assert.Equal(protocol1.GpsMinDistanceDelayMeters, protocol2.GpsMinDistanceDelayMeters);
Assert.Equal(protocol1.GpsMinTimeDelayMS, protocol2.GpsMinTimeDelayMS);
- Assert.Equal(protocol1.Groupable, protocol2.Groupable);
- Assert.Equal(protocol2.VariableValue.Count, 2);
- Assert.Equal(protocol2.VariableValue["var1"], "val2");
+ Assert.Equal(protocol1.Groupable, protocol2.Groupable);
+ Assert.Equal(protocol2.VariableValue.Count, 2);
+ Assert.Equal(protocol2.VariableValue["var1"], "val2");
Assert.Equal(protocol2.VariableValue["var2"], null);
}
@@ -114,4 +119,4 @@ public async Task ProtocolSerializeDeserializeTest()
// });
//}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/SensusServiceHelperTests.cs b/Sensus.Shared.Tests/Sensus.Shared/SensusServiceHelperTests.cs
index 59bc4f7f9..0986261ae 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/SensusServiceHelperTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/SensusServiceHelperTests.cs
@@ -1,226 +1,231 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System.Linq;
-using Newtonsoft.Json;
-using Xunit;
-using Sensus.Tests.Classes;
-using Sensus.Probes.Location;
-using Sensus.Probes.User.Scripts;
-using System;
-using System.Threading.Tasks;
-using Sensus.Context;
-
-namespace Sensus.Tests
-{
- public class SensusServiceHelperTests
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System.Linq;
+using Newtonsoft.Json;
+using Xunit;
+using Sensus.Tests.Classes;
+using Sensus.Probes.Location;
+using Sensus.Probes.User.Scripts;
+using System;
+using System.Threading.Tasks;
+using Sensus.Context;
+
+namespace Sensus.Tests
+{
+ public class SensusServiceHelperTests
{
private JsonSerializerSettings _jsonSerializerSettings;
- public SensusServiceHelperTests()
- {
- _jsonSerializerSettings = SensusServiceHelper.JSON_SERIALIZER_SETTINGS;
-
- //we don't want to quietly handle errors when testing.
- _jsonSerializerSettings.Error = null;
-
- SensusServiceHelper.ClearSingleton();
+ public SensusServiceHelperTests()
+ {
+ _jsonSerializerSettings = SensusServiceHelper.JSON_SERIALIZER_SETTINGS;
+
+ //we don't want to quietly handle errors when testing.
+ _jsonSerializerSettings.Error = null;
+
+ SensusServiceHelper.ClearSingleton();
+ }
+
+ [Fact]
+ public void SerializeAndDeserializeNoExceptionTest()
+ {
+ var service1 = new TestSensusServiceHelper();
+
+ var serial1 = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
+ service1.RegisteredProtocols.Clear();
+ var service2 = JsonConvert.DeserializeObject(serial1, _jsonSerializerSettings);
+
+ Assert.Equal(0, service1.RegisteredProtocols.Count);
+ Assert.Equal(0, service2.RegisteredProtocols.Count);
+ }
+
+ [Fact]
+ public async Task RegisteredOneProtocolTest()
+ {
+ TestSensusServiceHelper service1 = new TestSensusServiceHelper();
+ SensusServiceHelper.Initialize(() => service1);
+
+ service1.RegisteredProtocols.Clear();
+
+ Protocol protocol = await Protocol.CreateAsync("asdf");
+
+ var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
+
+ SensusServiceHelper.ClearSingleton();
+
+ TestSensusServiceHelper service2 = null;
+ SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
+ {
+ service2 = JsonConvert.DeserializeObject(serial, _jsonSerializerSettings);
+ });
+
+ Assert.Equal(service1.RegisteredProtocols.Count, service2.RegisteredProtocols.Count);
+ Assert.Equal(service1.RegisteredProtocols.First().Name, service2.RegisteredProtocols.First().Name);
+ }
+
+ [Fact]
+ public async Task RegisteredTwoProtocolsTest()
+ {
+ TestSensusServiceHelper service1 = new TestSensusServiceHelper();
+ SensusServiceHelper.Initialize(() => service1);
+
+ service1.RegisteredProtocols.Clear();
+
+ await Protocol.CreateAsync("Test1");
+ await Protocol.CreateAsync("Test2");
+
+ var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
+
+ SensusServiceHelper.ClearSingleton();
+
+ TestSensusServiceHelper service2 = null;
+ SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
+ {
+ service2 = JsonConvert.DeserializeObject(serial, _jsonSerializerSettings);
+ });
+
+ Assert.Equal(2, service1.RegisteredProtocols.Count);
+ Assert.Equal(2, service2.RegisteredProtocols.Count);
+
+ Assert.Equal(service1.RegisteredProtocols.Skip(0).Take(1).Single().Name, service2.RegisteredProtocols.Skip(0).Take(1).Single().Name);
+ Assert.Equal(service1.RegisteredProtocols.Skip(1).Take(1).Single().Name, service2.RegisteredProtocols.Skip(1).Take(1).Single().Name);
+ }
+
+ [Fact]
+ public async Task RunningProtocolIdsTest()
+ {
+ var service1 = new TestSensusServiceHelper();
+ SensusServiceHelper.Initialize(() => service1);
+
+ await Protocol.CreateAsync("Test");
+
+ service1.RunningProtocolIds.Clear();
+ service1.RunningProtocolIds.Add(service1.RegisteredProtocols.Single().Id);
+
+ var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
+
+ SensusServiceHelper.ClearSingleton();
+
+ TestSensusServiceHelper service2 = null;
+ SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
+ {
+ service2 = JsonConvert.DeserializeObject(serial, _jsonSerializerSettings);
+ });
+
+ Assert.Equal(service1.RunningProtocolIds.Count, service2.RunningProtocolIds.Count);
+ Assert.Equal(service1.RunningProtocolIds.Single(), service2.RunningProtocolIds.Single());
}
- [Fact]
- public void SerializeAndDeserializeNoExceptionTest()
- {
+ [Fact]
+ public void PointsOfInterestTest()
+ {
var service1 = new TestSensusServiceHelper();
+ SensusServiceHelper.Initialize(() => service1);
+
+ service1.PointsOfInterest.Clear();
+ service1.PointsOfInterest.Add(new PointOfInterest("Test", "Test", null));
+
+ var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
- var serial1 = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
- service1.RegisteredProtocols.Clear();
- var service2 = JsonConvert.DeserializeObject(serial1, _jsonSerializerSettings);
-
- Assert.Equal(0, service1.RegisteredProtocols.Count);
- Assert.Equal(0, service2.RegisteredProtocols.Count);
- }
-
- [Fact]
- public async Task RegisteredOneProtocolTest()
- {
- TestSensusServiceHelper service1 = new TestSensusServiceHelper();
- SensusServiceHelper.Initialize(() => service1);
-
- service1.RegisteredProtocols.Clear();
-
- Protocol protocol = await Protocol.CreateAsync("asdf");
-
- var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
-
- SensusServiceHelper.ClearSingleton();
-
- TestSensusServiceHelper service2 = null;
- SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
- {
- service2 = JsonConvert.DeserializeObject(serial, _jsonSerializerSettings);
- });
-
- Assert.Equal(service1.RegisteredProtocols.Count, service2.RegisteredProtocols.Count);
- Assert.Equal(service1.RegisteredProtocols.First().Name, service2.RegisteredProtocols.First().Name);
+ SensusServiceHelper.ClearSingleton();
+
+ var service2 = JsonConvert.DeserializeObject(serial, _jsonSerializerSettings);
+
+ Assert.Equal(service1.PointsOfInterest.Count, service2.PointsOfInterest.Count);
+ Assert.Equal(service1.PointsOfInterest.Single().Name, service2.PointsOfInterest.Single().Name);
}
[Fact]
- public async Task RegisteredTwoProtocolsTest()
- {
- TestSensusServiceHelper service1 = new TestSensusServiceHelper();
- SensusServiceHelper.Initialize(() => service1);
-
- service1.RegisteredProtocols.Clear();
-
- await Protocol.CreateAsync("Test1");
- await Protocol.CreateAsync("Test2");
-
- var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
-
- SensusServiceHelper.ClearSingleton();
-
- TestSensusServiceHelper service2 = null;
- SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
- {
- service2 = JsonConvert.DeserializeObject(serial, _jsonSerializerSettings);
- });
-
- Assert.Equal(2, service1.RegisteredProtocols.Count);
- Assert.Equal(2, service2.RegisteredProtocols.Count);
-
- Assert.Equal(service1.RegisteredProtocols.Skip(0).Take(1).Single().Name, service2.RegisteredProtocols.Skip(0).Take(1).Single().Name);
- Assert.Equal(service1.RegisteredProtocols.Skip(1).Take(1).Single().Name, service2.RegisteredProtocols.Skip(1).Take(1).Single().Name);
- }
-
- [Fact]
- public async Task RunningProtocolIdsTest()
- {
- var service1 = new TestSensusServiceHelper();
- SensusServiceHelper.Initialize(() => service1);
-
- await Protocol.CreateAsync("Test");
-
- service1.RunningProtocolIds.Clear();
- service1.RunningProtocolIds.Add(service1.RegisteredProtocols.Single().Id);
-
- var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
-
- SensusServiceHelper.ClearSingleton();
-
- TestSensusServiceHelper service2 = null;
- SensusContext.Current.MainThreadSynchronizer.ExecuteThreadSafe(() =>
- {
- service2 = JsonConvert.DeserializeObject(serial, _jsonSerializerSettings);
- });
-
- Assert.Equal(service1.RunningProtocolIds.Count, service2.RunningProtocolIds.Count);
- Assert.Equal(service1.RunningProtocolIds.Single(), service2.RunningProtocolIds.Single());
- }
-
- [Fact]
- public void PointsOfInterestTest()
- {
- var service1 = new TestSensusServiceHelper();
- SensusServiceHelper.Initialize(() => service1);
-
- service1.PointsOfInterest.Clear();
- service1.PointsOfInterest.Add(new PointOfInterest("Test", "Test", null));
-
- var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
-
- SensusServiceHelper.ClearSingleton();
-
- var service2 = JsonConvert.DeserializeObject(serial, _jsonSerializerSettings);
-
- Assert.Equal(service1.PointsOfInterest.Count, service2.PointsOfInterest.Count);
- Assert.Equal(service1.PointsOfInterest.Single().Name, service2.PointsOfInterest.Single().Name);
- }
-
- [Fact]
- public void FlashNotificationsEnabledTest()
- {
- var service1 = new TestSensusServiceHelper();
- SensusServiceHelper.Initialize(() => service1);
-
- service1.FlashNotificationsEnabled = true;
-
- var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
-
- SensusServiceHelper.ClearSingleton();
-
- var service2 = JsonConvert.DeserializeObject(serial);
-
- Assert.Equal(service1.FlashNotificationsEnabled, service2.FlashNotificationsEnabled);
-
- service1.FlashNotificationsEnabled = false;
-
- serial = JsonConvert.SerializeObject(service1);
-
- SensusServiceHelper.ClearSingleton();
-
- service2 = JsonConvert.DeserializeObject(serial);
-
- Assert.Equal(service1.FlashNotificationsEnabled, service2.FlashNotificationsEnabled);
- }
-
- [Fact]
- public void ScriptsToRunTest()
- {
- var service1 = new TestSensusServiceHelper();
- SensusServiceHelper.Initialize(() => service1);
-
- service1.RunningProtocolIds.Clear();
-
- service1.ScriptsToRun.Add(new Script(new ScriptRunner("Test", new ScriptProbe())));
-
- var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
-
- SensusServiceHelper.ClearSingleton();
-
- var service2 = JsonConvert.DeserializeObject(serial);
-
- Assert.Equal(service1.ScriptsToRun.Count, service2.ScriptsToRun.Count);
- Assert.Equal(service1.ScriptsToRun.Single().Id, service2.ScriptsToRun.Single().Id);
- }
-
- [Fact]
- public async Task ScriptsDisplayDateTimeOrderTest()
- {
- var service1 = new TestSensusServiceHelper();
- SensusServiceHelper.Initialize(() => service1);
-
- ScriptRunner runner = new ScriptRunner("Test", new ScriptProbe());
- Random random = new Random();
- for (int i = 0; i < 50; ++i)
- {
- Script script = new Script(runner);
- script.ScheduledRunTime = new DateTimeOffset(2000, 1, 1, 0, 0, 0, TimeSpan.Zero).AddMinutes(random.Next(-100000, 100000));
- await service1.AddScriptAsync(script, RunMode.Multiple);
- }
-
- Script scriptMin = new Script(runner);
- scriptMin.ScheduledRunTime = DateTimeOffset.MinValue;
- await service1.AddScriptAsync(scriptMin, RunMode.Multiple);
-
- Script scriptMax = new Script(runner);
- scriptMax.ScheduledRunTime = DateTimeOffset.MaxValue;
- await service1.AddScriptAsync(scriptMax, RunMode.Multiple);
-
- for (int i = 1; i < service1.ScriptsToRun.Count; ++i)
- {
- Assert.True(service1.ScriptsToRun.ElementAt(i).DisplayDateTime >= service1.ScriptsToRun.ElementAt(i - 1).DisplayDateTime);
- }
- }
- }
-}
+ public void FlashNotificationsEnabledTest()
+ {
+ var service1 = new TestSensusServiceHelper();
+ SensusServiceHelper.Initialize(() => service1);
+
+ service1.FlashNotificationsEnabled = true;
+
+ var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
+
+ SensusServiceHelper.ClearSingleton();
+
+ var service2 = JsonConvert.DeserializeObject(serial);
+
+ Assert.Equal(service1.FlashNotificationsEnabled, service2.FlashNotificationsEnabled);
+
+ service1.FlashNotificationsEnabled = false;
+
+ serial = JsonConvert.SerializeObject(service1);
+
+ SensusServiceHelper.ClearSingleton();
+
+ service2 = JsonConvert.DeserializeObject(serial);
+
+ Assert.Equal(service1.FlashNotificationsEnabled, service2.FlashNotificationsEnabled);
+ }
+
+ [Fact]
+ public void ScriptsToRunTest()
+ {
+ var service1 = new TestSensusServiceHelper();
+ SensusServiceHelper.Initialize(() => service1);
+
+ service1.RunningProtocolIds.Clear();
+
+ service1.ScriptsToRun.Add(new Script(new ScriptRunner("Test", new ScriptProbe())));
+
+ var serial = JsonConvert.SerializeObject(service1, _jsonSerializerSettings);
+
+ SensusServiceHelper.ClearSingleton();
+
+ var service2 = JsonConvert.DeserializeObject(serial);
+
+ Assert.Equal(service1.ScriptsToRun.Count, service2.ScriptsToRun.Count);
+ Assert.Equal(service1.ScriptsToRun.Single().Id, service2.ScriptsToRun.Single().Id);
+ }
+
+ [Fact]
+ public async Task ScriptsDisplayDateTimeOrderTest()
+ {
+ var service1 = new TestSensusServiceHelper();
+ SensusServiceHelper.Initialize(() => service1);
+
+ ScriptRunner runner = new ScriptRunner("Test", new ScriptProbe());
+ Random random = new Random();
+ for (int i = 0; i < 50; ++i)
+ {
+ Script script = new Script(runner);
+ script.ScheduledRunTime = new DateTimeOffset(2000, 1, 1, 0, 0, 0, TimeSpan.Zero).AddMinutes(random.Next(-100000, 100000));
+ await service1.AddScriptAsync(script, RunMode.Multiple);
+ }
+
+ Script scriptMin = new Script(runner);
+ scriptMin.ScheduledRunTime = DateTimeOffset.MinValue;
+ await service1.AddScriptAsync(scriptMin, RunMode.Multiple);
+
+ Script scriptMax = new Script(runner);
+ scriptMax.ScheduledRunTime = DateTimeOffset.MaxValue;
+ await service1.AddScriptAsync(scriptMax, RunMode.Multiple);
+
+ for (int i = 1; i < service1.ScriptsToRun.Count; ++i)
+ {
+ Assert.True(service1.ScriptsToRun.ElementAt(i).DisplayDateTime >= service1.ScriptsToRun.ElementAt(i - 1).DisplayDateTime);
+ }
+ }
+ }
+}
diff --git a/Sensus.Shared.Tests/Sensus.Shared/UI/Inputs/InputGroupTests.cs b/Sensus.Shared.Tests/Sensus.Shared/UI/Inputs/InputGroupTests.cs
index d8aa3f41e..bcd2dda53 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/UI/Inputs/InputGroupTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/UI/Inputs/InputGroupTests.cs
@@ -1,4 +1,22 @@
-using System.Linq;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+using System.Linq;
using Xunit;
using Sensus.UI.Inputs;
diff --git a/Sensus.Shared.Tests/Sensus.Shared/WindowTests.cs b/Sensus.Shared.Tests/Sensus.Shared/WindowTests.cs
index 6da5cf103..9fde97017 100644
--- a/Sensus.Shared.Tests/Sensus.Shared/WindowTests.cs
+++ b/Sensus.Shared.Tests/Sensus.Shared/WindowTests.cs
@@ -1,19 +1,24 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System;
-using Xunit;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System;
+using Xunit;
namespace Sensus.Tests
{
@@ -73,61 +78,61 @@ public void WindowScheduleCompareToEqual()
var t2 = new Window("10:22-12:22");
Assert.Equal(0, t1.CompareTo(t2));
- }
-
- [Fact]
- public void DowPointScheduleTriggerParse()
- {
- var t = new Window("Su-10:22");
-
- Assert.Equal(new TimeSpan(0, 10, 22, 0), t.Start);
- Assert.Equal(new TimeSpan(0, 10, 22, 0), t.End);
- Assert.Equal(TimeSpan.Zero, t.Duration);
- }
-
- [Fact]
- public void DowWindowScheduleTriggerParse()
- {
- var t = new Window("Mo-10:22-12:22");
-
- Assert.Equal(new TimeSpan(0, 10, 22, 0), t.Start);
- Assert.Equal(new TimeSpan(0, 12, 22, 0), t.End);
- Assert.Equal(TimeSpan.FromHours(2), t.Duration);
- }
-
- [Fact]
- public void DowPointScheduleToString()
- {
- var t = new Window("Tu-10:22");
-
- Assert.Equal("Tu-10:22", t.ToString());
- }
-
- [Fact]
- public void DowWindowScheduleToString()
- {
- var t = new Window("We-10:22-12:22");
-
- Assert.Equal("We-10:22-12:22", t.ToString());
- }
-
- [Fact]
- public void DowWindowScheduleCompareToDifferent()
- {
- var t1 = new Window("Th-10:22-12:22");
- var t2 = new Window("Fr-10:22-12:22");
-
- Assert.True(t1.CompareTo(t2) <= 0);
- Assert.True(t2.CompareTo(t1) >= 0);
- }
-
- [Fact]
- public void DowWindowScheduleCompareToEqual()
- {
- var t1 = new Window("Sa-10:22-12:22");
- var t2 = new Window("Sa-10:22-12:22");
-
- Assert.Equal(0, t1.CompareTo(t2));
+ }
+
+ [Fact]
+ public void DowPointScheduleTriggerParse()
+ {
+ var t = new Window("Su-10:22");
+
+ Assert.Equal(new TimeSpan(0, 10, 22, 0), t.Start);
+ Assert.Equal(new TimeSpan(0, 10, 22, 0), t.End);
+ Assert.Equal(TimeSpan.Zero, t.Duration);
+ }
+
+ [Fact]
+ public void DowWindowScheduleTriggerParse()
+ {
+ var t = new Window("Mo-10:22-12:22");
+
+ Assert.Equal(new TimeSpan(0, 10, 22, 0), t.Start);
+ Assert.Equal(new TimeSpan(0, 12, 22, 0), t.End);
+ Assert.Equal(TimeSpan.FromHours(2), t.Duration);
+ }
+
+ [Fact]
+ public void DowPointScheduleToString()
+ {
+ var t = new Window("Tu-10:22");
+
+ Assert.Equal("Tu-10:22", t.ToString());
+ }
+
+ [Fact]
+ public void DowWindowScheduleToString()
+ {
+ var t = new Window("We-10:22-12:22");
+
+ Assert.Equal("We-10:22-12:22", t.ToString());
+ }
+
+ [Fact]
+ public void DowWindowScheduleCompareToDifferent()
+ {
+ var t1 = new Window("Th-10:22-12:22");
+ var t2 = new Window("Fr-10:22-12:22");
+
+ Assert.True(t1.CompareTo(t2) <= 0);
+ Assert.True(t2.CompareTo(t1) >= 0);
+ }
+
+ [Fact]
+ public void DowWindowScheduleCompareToEqual()
+ {
+ var t1 = new Window("Sa-10:22-12:22");
+ var t2 = new Window("Sa-10:22-12:22");
+
+ Assert.Equal(0, t1.CompareTo(t2));
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/AnalyticsTrackedEvent.cs b/Sensus.Shared/AnalyticsTrackedEvent.cs
index 42958e8c4..3ac9de776 100644
--- a/Sensus.Shared/AnalyticsTrackedEvent.cs
+++ b/Sensus.Shared/AnalyticsTrackedEvent.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
diff --git a/Sensus.Shared/Anonymization/Anonymizable.cs b/Sensus.Shared/Anonymization/Anonymizable.cs
index 7c9e59b8b..d963f7472 100644
--- a/Sensus.Shared/Anonymization/Anonymizable.cs
+++ b/Sensus.Shared/Anonymization/Anonymizable.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
@@ -99,4 +104,4 @@ public Anonymizable(string propertyDisplayName, Type anonymizerType, bool anonym
{
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Anonymization/AnonymizedJsonContractResolver.cs b/Sensus.Shared/Anonymization/AnonymizedJsonContractResolver.cs
index a49466001..cf0446900 100644
--- a/Sensus.Shared/Anonymization/AnonymizedJsonContractResolver.cs
+++ b/Sensus.Shared/Anonymization/AnonymizedJsonContractResolver.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json.Serialization;
@@ -237,4 +242,4 @@ protected override IValueProvider CreateMemberValueProvider(MemberInfo member)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Anonymization/Anonymizers/Anonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/Anonymizer.cs
index c520bc160..a423352a4 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/Anonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/Anonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Newtonsoft.Json;
diff --git a/Sensus.Shared/Anonymization/Anonymizers/DateTimeOffsetTimelineAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/DateTimeOffsetTimelineAnonymizer.cs
index 43b3ef710..fefcb4a69 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/DateTimeOffsetTimelineAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/DateTimeOffsetTimelineAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -53,4 +58,4 @@ public override object Apply(object value, Protocol protocol)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingAnonymizer.cs
index f256a7baa..d6d934c64 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -53,4 +58,4 @@ public override object Apply(object value, Protocol protocol)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingHundredsAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingHundredsAnonymizer.cs
index fb1ae11e3..25ffd4eb5 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingHundredsAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingHundredsAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
diff --git a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingHundredthsAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingHundredthsAnonymizer.cs
index ef386b492..bffe6a4a8 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingHundredthsAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingHundredthsAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -34,4 +39,4 @@ public DoubleRoundingHundredthsAnonymizer()
{
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingOnesAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingOnesAnonymizer.cs
index 4fc29c914..107859d64 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingOnesAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingOnesAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
diff --git a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingTensAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingTensAnonymizer.cs
index ffeab795f..7d80b6d28 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingTensAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingTensAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
diff --git a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingTenthsAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingTenthsAnonymizer.cs
index 90c219fc0..91688f171 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingTenthsAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingTenthsAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
diff --git a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingThousandthsAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingThousandthsAnonymizer.cs
index c2d49f0cb..f14eae47f 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingThousandthsAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/DoubleRoundingThousandthsAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
diff --git a/Sensus.Shared/Anonymization/Anonymizers/LongitudeOffsetGpsAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/LongitudeOffsetGpsAnonymizer.cs
index e8a7a6cd8..10223993a 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/LongitudeOffsetGpsAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/LongitudeOffsetGpsAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Extensions;
@@ -55,4 +60,4 @@ public override object Apply(object value, Protocol protocol)
return offsetValue;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Anonymization/Anonymizers/LongitudeParticipantOffsetGpsAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/LongitudeParticipantOffsetGpsAnonymizer.cs
index 6d40828d0..ded93a905 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/LongitudeParticipantOffsetGpsAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/LongitudeParticipantOffsetGpsAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Anonymization.Anonymizers
{
@@ -37,4 +42,4 @@ protected override double GetOffset(Protocol protocol)
return protocol.GpsLongitudeAnonymizationParticipantOffset;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Anonymization/Anonymizers/LongitudeStudyOffsetGpsAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/LongitudeStudyOffsetGpsAnonymizer.cs
index d5065eb5e..ff211e518 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/LongitudeStudyOffsetGpsAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/LongitudeStudyOffsetGpsAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Anonymization.Anonymizers
{
@@ -36,4 +41,4 @@ protected override double GetOffset(Protocol protocol)
return protocol.GpsLongitudeAnonymizationStudyOffset;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Anonymization/Anonymizers/StringHashAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/StringHashAnonymizer.cs
index 389a0a5ad..a92c79775 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/StringHashAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/StringHashAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Exceptions;
diff --git a/Sensus.Shared/Anonymization/Anonymizers/ValueOmittingAnonymizer.cs b/Sensus.Shared/Anonymization/Anonymizers/ValueOmittingAnonymizer.cs
index f1c1329fd..0497ec08d 100644
--- a/Sensus.Shared/Anonymization/Anonymizers/ValueOmittingAnonymizer.cs
+++ b/Sensus.Shared/Anonymization/Anonymizers/ValueOmittingAnonymizer.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Anonymization.Anonymizers
{
diff --git a/Sensus.Shared/Callbacks/CallbackScheduler.cs b/Sensus.Shared/Callbacks/CallbackScheduler.cs
index a4c5af9b8..28688433f 100644
--- a/Sensus.Shared/Callbacks/CallbackScheduler.cs
+++ b/Sensus.Shared/Callbacks/CallbackScheduler.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Concurrent;
@@ -382,4 +387,4 @@ private PushNotificationRequest GetPushNotificationRequest(ScheduledCallback cal
return null;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Callbacks/ScheduledCallback.cs b/Sensus.Shared/Callbacks/ScheduledCallback.cs
index 68fcc51d9..12b07074d 100644
--- a/Sensus.Shared/Callbacks/ScheduledCallback.cs
+++ b/Sensus.Shared/Callbacks/ScheduledCallback.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
@@ -169,4 +174,4 @@ public ScheduledCallback(ActionDelegate action,
RepeatDelay = repeatDelay;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Callbacks/ScheduledCallbackState.cs b/Sensus.Shared/Callbacks/ScheduledCallbackState.cs
index 8a32dec54..90f82ce9c 100644
--- a/Sensus.Shared/Callbacks/ScheduledCallbackState.cs
+++ b/Sensus.Shared/Callbacks/ScheduledCallbackState.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
diff --git a/Sensus.Shared/Concurrent/ConcurrentObservableCollection.cs b/Sensus.Shared/Concurrent/ConcurrentObservableCollection.cs
index dc405ba2c..bf16aee1e 100644
--- a/Sensus.Shared/Concurrent/ConcurrentObservableCollection.cs
+++ b/Sensus.Shared/Concurrent/ConcurrentObservableCollection.cs
@@ -1,37 +1,42 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System.Collections;
-using System.ComponentModel;
-using System.Collections.Generic;
-using System.Collections.ObjectModel;
-using System.Collections.Specialized;
-using System.Diagnostics.CodeAnalysis;
-using Sensus.Context;
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System.Collections;
+using System.ComponentModel;
+using System.Collections.Generic;
+using System.Collections.ObjectModel;
+using System.Collections.Specialized;
+using System.Diagnostics.CodeAnalysis;
+using Sensus.Context;
+
namespace Sensus.Concurrent
{
///
/// Provides thread-safe concurrent access to an observable collection.
///
public class ConcurrentObservableCollection: INotifyCollectionChanged, INotifyPropertyChanged, ICollection
- {
- // This is terrifying and a bad idea on many levels. However, I think it is still better than sprinkling lock code throughout the entire system.
- // Someday Microsoft might come up with a clever lock free way to design random access data structures. When that happens we'll get rid of this.
-
- private readonly IConcurrent _concurrent;
-
+ {
+ // This is terrifying and a bad idea on many levels. However, I think it is still better than sprinkling lock code throughout the entire system.
+ // Someday Microsoft might come up with a clever lock free way to design random access data structures. When that happens we'll get rid of this.
+
+ private readonly IConcurrent _concurrent;
+
#region Fields
private readonly ObservableCollection _observableCollection;
#endregion
@@ -50,11 +55,11 @@ public event PropertyChangedEventHandler PropertyChanged
}
#endregion
- #region Properties
- public IConcurrent Concurrent
- {
- get { return _concurrent; }
- }
+ #region Properties
+ public IConcurrent Concurrent
+ {
+ get { return _concurrent; }
+ }
public int Count => _observableCollection.Count;
@@ -62,16 +67,16 @@ public IConcurrent Concurrent
#endregion
#region Constructors
- public ConcurrentObservableCollection()
- {
- _concurrent = SensusContext.Current.MainThreadSynchronizer;
- _observableCollection = new ObservableCollection();
+ public ConcurrentObservableCollection()
+ {
+ _concurrent = SensusContext.Current.MainThreadSynchronizer;
+ _observableCollection = new ObservableCollection();
}
- public ConcurrentObservableCollection(IConcurrent concurrent)
- {
- _concurrent = concurrent;
- _observableCollection = new ObservableCollection();
+ public ConcurrentObservableCollection(IConcurrent concurrent)
+ {
+ _concurrent = concurrent;
+ _observableCollection = new ObservableCollection();
}
#endregion
@@ -114,9 +119,9 @@ public void CopyTo(T[] array, int arrayIndex)
_observableCollection.CopyTo(array, arrayIndex);
}
- public bool Remove(T item)
- {
- return _concurrent.ExecuteThreadSafe(() => _observableCollection.Remove(item));
+ public bool Remove(T item)
+ {
+ return _concurrent.ExecuteThreadSafe(() => _observableCollection.Remove(item));
}
public void Insert(int index, T item)
@@ -148,4 +153,4 @@ private List Materialize()
}
#endregion
}
-}
+}
diff --git a/Sensus.Shared/Concurrent/IConcurrent.cs b/Sensus.Shared/Concurrent/IConcurrent.cs
index e99785fc1..bfa71a597 100644
--- a/Sensus.Shared/Concurrent/IConcurrent.cs
+++ b/Sensus.Shared/Concurrent/IConcurrent.cs
@@ -1,25 +1,30 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System;
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System;
+
namespace Sensus.Concurrent
-{
- public interface IConcurrent : IDisposable
- {
- void ExecuteThreadSafe(Action action);
-
- T ExecuteThreadSafe(Func func);
- }
-}
\ No newline at end of file
+{
+ public interface IConcurrent : IDisposable
+ {
+ void ExecuteThreadSafe(Action action);
+
+ T ExecuteThreadSafe(Func func);
+ }
+}
diff --git a/Sensus.Shared/Concurrent/LockConcurrent.cs b/Sensus.Shared/Concurrent/LockConcurrent.cs
index 66f04587e..42449c619 100644
--- a/Sensus.Shared/Concurrent/LockConcurrent.cs
+++ b/Sensus.Shared/Concurrent/LockConcurrent.cs
@@ -1,20 +1,25 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System;
-using Sensus.Dispose;
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System;
+using Sensus.Dispose;
+
namespace Sensus.Concurrent
{
public class LockConcurrent: Disposable, IConcurrent
@@ -24,39 +29,39 @@ public class LockConcurrent: Disposable, IConcurrent
#endregion
#region Constructors
- public LockConcurrent(object @lock = null)
+ public LockConcurrent(object @lock = null)
{
_lock = @lock ?? this;
}
#endregion
#region Public Methods
- public void ExecuteThreadSafe(Action action)
- {
- if (action == null)
- {
- throw new ArgumentNullException(nameof(action));
- }
-
- lock (_lock)
- {
- action();
- }
- }
-
- public T ExecuteThreadSafe(Func func)
+ public void ExecuteThreadSafe(Action action)
{
- if (func == null)
- {
- throw new ArgumentNullException(nameof(func));
- }
-
- lock (_lock)
- {
- return func();
- }
- }
-
+ if (action == null)
+ {
+ throw new ArgumentNullException(nameof(action));
+ }
+
+ lock (_lock)
+ {
+ action();
+ }
+ }
+
+ public T ExecuteThreadSafe(Func func)
+ {
+ if (func == null)
+ {
+ throw new ArgumentNullException(nameof(func));
+ }
+
+ lock (_lock)
+ {
+ return func();
+ }
+ }
+
#endregion
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Context/ISensusContext.cs b/Sensus.Shared/Context/ISensusContext.cs
index c40d1ff81..61fcfa312 100644
--- a/Sensus.Shared/Context/ISensusContext.cs
+++ b/Sensus.Shared/Context/ISensusContext.cs
@@ -1,22 +1,27 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-using Sensus.Callbacks;
+using Sensus.Callbacks;
using Sensus.Concurrent;
using Sensus.Encryption;
using Sensus.Notifications;
-
+
namespace Sensus.Context
{
///
@@ -34,4 +39,4 @@ public interface ISensusContext
string IamAccessKeySecret { get; set; }
PowerConnectionChangeListener PowerConnectionChangeListener { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Context/Platform.cs b/Sensus.Shared/Context/Platform.cs
index fffae2f5f..6dd1f767c 100644
--- a/Sensus.Shared/Context/Platform.cs
+++ b/Sensus.Shared/Context/Platform.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Context
{
diff --git a/Sensus.Shared/Context/SensusContext.cs b/Sensus.Shared/Context/SensusContext.cs
index 7f06a3ac6..137882104 100644
--- a/Sensus.Shared/Context/SensusContext.cs
+++ b/Sensus.Shared/Context/SensusContext.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Context
{
@@ -21,4 +26,4 @@ public static class SensusContext
{
public static ISensusContext Current { get; set; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/DataStores/Compressor.cs b/Sensus.Shared/DataStores/Compressor.cs
index ae4cf7e35..280be301a 100644
--- a/Sensus.Shared/DataStores/Compressor.cs
+++ b/Sensus.Shared/DataStores/Compressor.cs
@@ -1,75 +1,80 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
using System;
-using System.IO;
-using System.IO.Compression;
-
-namespace Sensus.DataStores
-{
- public class Compressor
- {
- public enum CompressionMethod
- {
- GZip
- }
-
- private CompressionMethod _method;
-
- public Compressor(CompressionMethod method)
- {
- _method = method;
- }
-
- public void Compress(byte[] bytesToCompress, Stream destinationStream)
- {
- if (_method == CompressionMethod.GZip)
- {
- using (GZipStream zip = new GZipStream(destinationStream, CompressionMode.Compress, true))
- {
- zip.Write(bytesToCompress, 0, bytesToCompress.Length);
- zip.Flush();
- }
- }
- else
- {
- throw new NotImplementedException("Unrecognized compression method: " + _method);
- }
- }
-
- public byte[] Decompress(Stream compressedStream)
- {
- if (_method == CompressionMethod.GZip)
- {
- MemoryStream decompressedStream = new MemoryStream();
-
- using (GZipStream zip = new GZipStream(compressedStream, CompressionMode.Decompress, true))
- {
- byte[] buffer = new byte[4096];
- int bytesRead;
- while ((bytesRead = zip.Read(buffer, 0, buffer.Length)) > 0)
- {
- decompressedStream.Write(buffer, 0, bytesRead);
- }
- }
-
- return decompressedStream.ToArray();
- }
- else
- {
- throw new NotImplementedException("Unrecognized compression method: " + _method);
- }
- }
- }
-}
\ No newline at end of file
+using System.IO;
+using System.IO.Compression;
+
+namespace Sensus.DataStores
+{
+ public class Compressor
+ {
+ public enum CompressionMethod
+ {
+ GZip
+ }
+
+ private CompressionMethod _method;
+
+ public Compressor(CompressionMethod method)
+ {
+ _method = method;
+ }
+
+ public void Compress(byte[] bytesToCompress, Stream destinationStream)
+ {
+ if (_method == CompressionMethod.GZip)
+ {
+ using (GZipStream zip = new GZipStream(destinationStream, CompressionMode.Compress, true))
+ {
+ zip.Write(bytesToCompress, 0, bytesToCompress.Length);
+ zip.Flush();
+ }
+ }
+ else
+ {
+ throw new NotImplementedException("Unrecognized compression method: " + _method);
+ }
+ }
+
+ public byte[] Decompress(Stream compressedStream)
+ {
+ if (_method == CompressionMethod.GZip)
+ {
+ MemoryStream decompressedStream = new MemoryStream();
+
+ using (GZipStream zip = new GZipStream(compressedStream, CompressionMode.Decompress, true))
+ {
+ byte[] buffer = new byte[4096];
+ int bytesRead;
+ while ((bytesRead = zip.Read(buffer, 0, buffer.Length)) > 0)
+ {
+ decompressedStream.Write(buffer, 0, bytesRead);
+ }
+ }
+
+ return decompressedStream.ToArray();
+ }
+ else
+ {
+ throw new NotImplementedException("Unrecognized compression method: " + _method);
+ }
+ }
+ }
+}
diff --git a/Sensus.Shared/DataStores/DataStore.cs b/Sensus.Shared/DataStores/DataStore.cs
index ad68da9e1..f952b0d77 100644
--- a/Sensus.Shared/DataStores/DataStore.cs
+++ b/Sensus.Shared/DataStores/DataStore.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Newtonsoft.Json;
using System;
@@ -149,4 +154,4 @@ public DataStore Copy()
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/DataStores/IClearableDataStore.cs b/Sensus.Shared/DataStores/IClearableDataStore.cs
index 85eb40881..37074847c 100644
--- a/Sensus.Shared/DataStores/IClearableDataStore.cs
+++ b/Sensus.Shared/DataStores/IClearableDataStore.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.DataStores
{
diff --git a/Sensus.Shared/DataStores/Local/FileLocalDataStore.cs b/Sensus.Shared/DataStores/Local/FileLocalDataStore.cs
index 1784b015b..ac9df70c8 100644
--- a/Sensus.Shared/DataStores/Local/FileLocalDataStore.cs
+++ b/Sensus.Shared/DataStores/Local/FileLocalDataStore.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Newtonsoft.Json;
using Sensus.Exceptions;
@@ -864,4 +869,4 @@ public override async Task TestHealthAsync(List TestHealthAsync(List GetScriptAgentPolicyAsync(CancellationToken cancell
throw new NotImplementedException();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/DataStores/Remote/RemoteDataStore.cs b/Sensus.Shared/DataStores/Remote/RemoteDataStore.cs
index 3ce3035fc..773966aa7 100644
--- a/Sensus.Shared/DataStores/Remote/RemoteDataStore.cs
+++ b/Sensus.Shared/DataStores/Remote/RemoteDataStore.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus.UI.UiProperties;
using System.Threading;
@@ -414,4 +419,4 @@ public async Task WriteLocalDataStoreAsync(CancellationToken cancellationT
/// The type of to retrieve.
public abstract Task GetDatumAsync(string datumKey, CancellationToken cancellationToken) where T : Datum;
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Datum.cs b/Sensus.Shared/Datum.cs
index eef62c08d..d176feaf2 100644
--- a/Sensus.Shared/Datum.cs
+++ b/Sensus.Shared/Datum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
diff --git a/Sensus.Shared/Dispose/Disposable.cs b/Sensus.Shared/Dispose/Disposable.cs
index 60880c4e5..c8f6cf6eb 100644
--- a/Sensus.Shared/Dispose/Disposable.cs
+++ b/Sensus.Shared/Dispose/Disposable.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -66,4 +71,4 @@ protected void DisposeCheck()
}
#endregion
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Encryption/AsymmetricEncryption.cs b/Sensus.Shared/Encryption/AsymmetricEncryption.cs
index 47501d249..de8f133ab 100644
--- a/Sensus.Shared/Encryption/AsymmetricEncryption.cs
+++ b/Sensus.Shared/Encryption/AsymmetricEncryption.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Org.BouncyCastle.Security;
@@ -160,4 +165,4 @@ public void EncryptSymmetrically(byte[] unencryptedBytes, int symmetricKeySizeBi
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Encryption/IEncryption.cs b/Sensus.Shared/Encryption/IEncryption.cs
index 7a97fb8eb..f235d1961 100644
--- a/Sensus.Shared/Encryption/IEncryption.cs
+++ b/Sensus.Shared/Encryption/IEncryption.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Encryption
{
@@ -20,4 +25,4 @@ public interface IEncryption
byte[] Encrypt(byte[] unencryptedBytes);
string DecryptToString(byte[] encryptedBytes);
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Encryption/SymmetricEncryption.cs b/Sensus.Shared/Encryption/SymmetricEncryption.cs
index 8fd260afc..ad718885a 100644
--- a/Sensus.Shared/Encryption/SymmetricEncryption.cs
+++ b/Sensus.Shared/Encryption/SymmetricEncryption.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System.Linq;
using System.Text;
@@ -34,13 +39,13 @@ public class SymmetricEncryption : IEncryption
///
///
public SymmetricEncryption(string encryptionKeyHexString)
- {
+ {
if (string.IsNullOrWhiteSpace(encryptionKeyHexString))
{
_encryptionKeyBytes = new byte[32];
}
else
- {
+ {
_encryptionKeyBytes = ConvertHexStringToByteArray(encryptionKeyHexString);
}
@@ -58,16 +63,16 @@ public SymmetricEncryption(byte[] encryptionKeyBytes, byte[] initializationVecto
_initializationVectorBytes = initializationVectorBytes;
}
- public static byte[] ConvertHexStringToByteArray(string hexString)
- {
+ public static byte[] ConvertHexStringToByteArray(string hexString)
+ {
byte[] bytes = new byte[hexString.Length / 2];
-
+
for (int i = 0; i < hexString.Length; i += 2)
- {
+ {
bytes[i / 2] = Convert.ToByte(hexString.Substring(i, 2), 16);
- }
-
- return bytes;
+ }
+
+ return bytes;
}
public byte[] Encrypt(string unencryptedValue)
@@ -91,16 +96,16 @@ public byte[] Encrypt(byte[] unencryptedBytes)
public string DecryptToString(byte[] encryptedBytes)
{
- using (AesCryptoServiceProvider aes = new AesCryptoServiceProvider())
- {
- aes.KeySize = _encryptionKeyBytes.Length * 8;
- aes.BlockSize = _initializationVectorBytes.Length * 8;
-
- using (ICryptoTransform transform = aes.CreateDecryptor(_encryptionKeyBytes, _initializationVectorBytes))
- {
- return Encoding.Unicode.GetString(transform.TransformFinalBlock(encryptedBytes, 0, encryptedBytes.Length));
- }
+ using (AesCryptoServiceProvider aes = new AesCryptoServiceProvider())
+ {
+ aes.KeySize = _encryptionKeyBytes.Length * 8;
+ aes.BlockSize = _initializationVectorBytes.Length * 8;
+
+ using (ICryptoTransform transform = aes.CreateDecryptor(_encryptionKeyBytes, _initializationVectorBytes))
+ {
+ return Encoding.Unicode.GetString(transform.TransformFinalBlock(encryptedBytes, 0, encryptedBytes.Length));
+ }
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Exceptions/SensusException.cs b/Sensus.Shared/Exceptions/SensusException.cs
index ef45c93c2..3b8f34c14 100644
--- a/Sensus.Shared/Exceptions/SensusException.cs
+++ b/Sensus.Shared/Exceptions/SensusException.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.AppCenter.Crashes;
@@ -97,4 +102,4 @@ protected SensusException(string message, Exception innerException = null)
{
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/ExtensionMethods.cs b/Sensus.Shared/ExtensionMethods.cs
index 3d1bbd659..64bcd1087 100644
--- a/Sensus.Shared/ExtensionMethods.cs
+++ b/Sensus.Shared/ExtensionMethods.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.ObjectModel;
@@ -46,4 +51,4 @@ public static void Shuffle(this Random random, Collection array)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Extensions/DateTimeExtensions.cs b/Sensus.Shared/Extensions/DateTimeExtensions.cs
index 13baad897..95f085723 100644
--- a/Sensus.Shared/Extensions/DateTimeExtensions.cs
+++ b/Sensus.Shared/Extensions/DateTimeExtensions.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -76,4 +81,4 @@ public static long ToJavaCurrentTimeMillis(this DateTime dateTime)
return (long)(dateTime.ToUniversalTime() - new DateTimeOffset(1970, 1, 1, 0, 0, 0, new TimeSpan())).TotalMilliseconds;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Extensions/EnumerableExtensions.cs b/Sensus.Shared/Extensions/EnumerableExtensions.cs
index df9fb2e76..e96dd92b7 100644
--- a/Sensus.Shared/Extensions/EnumerableExtensions.cs
+++ b/Sensus.Shared/Extensions/EnumerableExtensions.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System.Linq;
using System.Collections.Generic;
@@ -40,4 +45,4 @@ public static ObservableCollection ToObservableCollection(this IEnumerable
return collection;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Extensions/NumericExtensions.cs b/Sensus.Shared/Extensions/NumericExtensions.cs
index 53fc89de6..fafe104b5 100644
--- a/Sensus.Shared/Extensions/NumericExtensions.cs
+++ b/Sensus.Shared/Extensions/NumericExtensions.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -69,4 +74,4 @@ public static double NextDouble(this Random random, double min, double max)
return min + random.NextDouble() * (max - min);
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Extensions/TimeSpanExtensions.cs b/Sensus.Shared/Extensions/TimeSpanExtensions.cs
index c2948ecbd..ac49fe843 100644
--- a/Sensus.Shared/Extensions/TimeSpanExtensions.cs
+++ b/Sensus.Shared/Extensions/TimeSpanExtensions.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
diff --git a/Sensus.Shared/GlobalSuppressions.cs b/Sensus.Shared/GlobalSuppressions.cs
index c2a657f14..426eda0a8 100644
--- a/Sensus.Shared/GlobalSuppressions.cs
+++ b/Sensus.Shared/GlobalSuppressions.cs
@@ -1,8 +1,26 @@
-
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
// This file is used by Code Analysis to maintain SuppressMessage
// attributes that are applied to this project.
// Project-level suppressions either have no target or are given
// a specific target and scoped to a namespace, type, member, etc.
-[assembly: System.Diagnostics.CodeAnalysis.SuppressMessage("Style", "IDE0019:Use pattern matching", Justification = "", Scope = "member", Target = "~M:Sensus.UI.TaggingPage.#ctor(Sensus.Protocol)")]
-
+[assembly: System.Diagnostics.CodeAnalysis.SuppressMessage("Style", "IDE0019:Use pattern matching", Justification = "", Scope = "member", Target = "~M:Sensus.UI.TaggingPage.#ctor(Sensus.Protocol)")]
+
diff --git a/Sensus.Shared/HealthTestResult.cs b/Sensus.Shared/HealthTestResult.cs
index ac6671380..1eab66716 100644
--- a/Sensus.Shared/HealthTestResult.cs
+++ b/Sensus.Shared/HealthTestResult.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus
{
diff --git a/Sensus.Shared/HeartbeatDatum.cs b/Sensus.Shared/HeartbeatDatum.cs
index cf40bc5f1..b95c9ad2f 100644
--- a/Sensus.Shared/HeartbeatDatum.cs
+++ b/Sensus.Shared/HeartbeatDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -40,4 +45,4 @@ public HeartbeatDatum(DateTimeOffset timestamp)
{
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/ImpreciseDatum.cs b/Sensus.Shared/ImpreciseDatum.cs
index 0a432d538..3a5526c3a 100644
--- a/Sensus.Shared/ImpreciseDatum.cs
+++ b/Sensus.Shared/ImpreciseDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus.Probes;
using System;
diff --git a/Sensus.Shared/Logger.cs b/Sensus.Shared/Logger.cs
index 66226043d..60e435cf8 100644
--- a/Sensus.Shared/Logger.cs
+++ b/Sensus.Shared/Logger.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.IO;
@@ -233,4 +238,4 @@ public virtual void Clear()
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Notifications/DisplayPage.cs b/Sensus.Shared/Notifications/DisplayPage.cs
index 05963565d..d3c547d02 100644
--- a/Sensus.Shared/Notifications/DisplayPage.cs
+++ b/Sensus.Shared/Notifications/DisplayPage.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Notifications
{
@@ -29,4 +34,4 @@ public enum DisplayPage
///
PendingSurveys
};
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Notifications/Notifier.cs b/Sensus.Shared/Notifications/Notifier.cs
index 05801ab12..c0381fbac 100644
--- a/Sensus.Shared/Notifications/Notifier.cs
+++ b/Sensus.Shared/Notifications/Notifier.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus.Context;
using Sensus.Exceptions;
@@ -425,4 +430,4 @@ public async Task TestHealthAsync(CancellationToken cancellationToken)
#endregion
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Notifications/PushNotificationRequest.cs b/Sensus.Shared/Notifications/PushNotificationRequest.cs
index f25c1479c..b34b9b3e6 100644
--- a/Sensus.Shared/Notifications/PushNotificationRequest.cs
+++ b/Sensus.Shared/Notifications/PushNotificationRequest.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Exceptions;
@@ -137,4 +142,4 @@ public override int GetHashCode()
return _id.GetHashCode();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Notifications/PushNotificationRequestFormat.cs b/Sensus.Shared/Notifications/PushNotificationRequestFormat.cs
index 5ae5322c5..092bba1cc 100644
--- a/Sensus.Shared/Notifications/PushNotificationRequestFormat.cs
+++ b/Sensus.Shared/Notifications/PushNotificationRequestFormat.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Notifications
{
diff --git a/Sensus.Shared/ParticipationReportDatum.cs b/Sensus.Shared/ParticipationReportDatum.cs
index a91d2af5d..4409e7414 100644
--- a/Sensus.Shared/ParticipationReportDatum.cs
+++ b/Sensus.Shared/ParticipationReportDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus.Probes;
using System;
diff --git a/Sensus.Shared/ParticipationRewardDatum.cs b/Sensus.Shared/ParticipationRewardDatum.cs
index 9aac2f60e..b963d4ec7 100644
--- a/Sensus.Shared/ParticipationRewardDatum.cs
+++ b/Sensus.Shared/ParticipationRewardDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -64,4 +69,4 @@ public override string ToString()
"Participation: " + _participation;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/PowerConnectionChangeListener.cs b/Sensus.Shared/PowerConnectionChangeListener.cs
index 29e5c89ba..934ab7955 100644
--- a/Sensus.Shared/PowerConnectionChangeListener.cs
+++ b/Sensus.Shared/PowerConnectionChangeListener.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
diff --git a/Sensus.Shared/Probes/Apps/FacebookDatum.cs b/Sensus.Shared/Probes/Apps/FacebookDatum.cs
index 26f0c0899..6879345ad 100644
--- a/Sensus.Shared/Probes/Apps/FacebookDatum.cs
+++ b/Sensus.Shared/Probes/Apps/FacebookDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Reflection;
@@ -235,4 +240,4 @@ public FacebookDatum(DateTimeOffset timestamp)
{
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Apps/FacebookPermission.cs b/Sensus.Shared/Probes/Apps/FacebookPermission.cs
index f3cc0e5e3..aa961184b 100644
--- a/Sensus.Shared/Probes/Apps/FacebookPermission.cs
+++ b/Sensus.Shared/Probes/Apps/FacebookPermission.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Exceptions;
@@ -57,4 +62,4 @@ public override string ToString()
return _name;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Apps/FacebookProbe.cs b/Sensus.Shared/Probes/Apps/FacebookProbe.cs
index b34123637..849436304 100644
--- a/Sensus.Shared/Probes/Apps/FacebookProbe.cs
+++ b/Sensus.Shared/Probes/Apps/FacebookProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Linq;
@@ -168,4 +173,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
throw new NotImplementedException();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Communication/ListeningTelephonyProbe.cs b/Sensus.Shared/Probes/Communication/ListeningTelephonyProbe.cs
index 647ae9684..726c04859 100644
--- a/Sensus.Shared/Probes/Communication/ListeningTelephonyProbe.cs
+++ b/Sensus.Shared/Probes/Communication/ListeningTelephonyProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
diff --git a/Sensus.Shared/Probes/Communication/PollingTelephonyProbe.cs b/Sensus.Shared/Probes/Communication/PollingTelephonyProbe.cs
index b23d908ff..bfd0e463c 100644
--- a/Sensus.Shared/Probes/Communication/PollingTelephonyProbe.cs
+++ b/Sensus.Shared/Probes/Communication/PollingTelephonyProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Syncfusion.SfChart.XForms;
@@ -65,4 +70,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
throw new NotImplementedException();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Communication/SmsDatum.cs b/Sensus.Shared/Probes/Communication/SmsDatum.cs
index 835fc2c30..7aad6f6bb 100644
--- a/Sensus.Shared/Probes/Communication/SmsDatum.cs
+++ b/Sensus.Shared/Probes/Communication/SmsDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Text.RegularExpressions;
diff --git a/Sensus.Shared/Probes/Communication/SmsProbe.cs b/Sensus.Shared/Probes/Communication/SmsProbe.cs
index 7134eb174..4880583bd 100644
--- a/Sensus.Shared/Probes/Communication/SmsProbe.cs
+++ b/Sensus.Shared/Probes/Communication/SmsProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
diff --git a/Sensus.Shared/Probes/Communication/TelephonyDatum.cs b/Sensus.Shared/Probes/Communication/TelephonyDatum.cs
index 8cb82f1f3..0a58d93d2 100644
--- a/Sensus.Shared/Probes/Communication/TelephonyDatum.cs
+++ b/Sensus.Shared/Probes/Communication/TelephonyDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -102,4 +107,4 @@ public override string ToString()
"Duration (Secs.): " + _callDurationSeconds.GetValueOrDefault());
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Context/AmbientTemperatureDatum.cs b/Sensus.Shared/Probes/Context/AmbientTemperatureDatum.cs
index c6957c426..872793578 100644
--- a/Sensus.Shared/Probes/Context/AmbientTemperatureDatum.cs
+++ b/Sensus.Shared/Probes/Context/AmbientTemperatureDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -76,4 +81,4 @@ public override string ToString()
"Degrees (C): " + _degreesCelsius;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Context/BluetoothCharacteristicReadArgs.cs b/Sensus.Shared/Probes/Context/BluetoothCharacteristicReadArgs.cs
index 1151ba28d..c8ee93188 100644
--- a/Sensus.Shared/Probes/Context/BluetoothCharacteristicReadArgs.cs
+++ b/Sensus.Shared/Probes/Context/BluetoothCharacteristicReadArgs.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
diff --git a/Sensus.Shared/Probes/Context/BluetoothDeviceProximityDatum.cs b/Sensus.Shared/Probes/Context/BluetoothDeviceProximityDatum.cs
index 6e9e6e3f8..517fefc8c 100644
--- a/Sensus.Shared/Probes/Context/BluetoothDeviceProximityDatum.cs
+++ b/Sensus.Shared/Probes/Context/BluetoothDeviceProximityDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
diff --git a/Sensus.Shared/Probes/Context/BluetoothDeviceProximityProbe.cs b/Sensus.Shared/Probes/Context/BluetoothDeviceProximityProbe.cs
index 99d8d9424..91c312420 100644
--- a/Sensus.Shared/Probes/Context/BluetoothDeviceProximityProbe.cs
+++ b/Sensus.Shared/Probes/Context/BluetoothDeviceProximityProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
diff --git a/Sensus.Shared/Probes/Context/HumidityDatum.cs b/Sensus.Shared/Probes/Context/HumidityDatum.cs
index 8acc34e2a..b54430ff2 100644
--- a/Sensus.Shared/Probes/Context/HumidityDatum.cs
+++ b/Sensus.Shared/Probes/Context/HumidityDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -70,4 +75,4 @@ public override string ToString()
"Relative Humidity: " + _relativeHumidity;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Context/HumidityProbe.cs b/Sensus.Shared/Probes/Context/HumidityProbe.cs
index 395fdd056..e54ac6dac 100644
--- a/Sensus.Shared/Probes/Context/HumidityProbe.cs
+++ b/Sensus.Shared/Probes/Context/HumidityProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -95,4 +100,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Context/LightDatum.cs b/Sensus.Shared/Probes/Context/LightDatum.cs
index 1cc154503..38289bd39 100644
--- a/Sensus.Shared/Probes/Context/LightDatum.cs
+++ b/Sensus.Shared/Probes/Context/LightDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
diff --git a/Sensus.Shared/Probes/Context/LightProbe.cs b/Sensus.Shared/Probes/Context/LightProbe.cs
index f517909b1..fc7f248d3 100644
--- a/Sensus.Shared/Probes/Context/LightProbe.cs
+++ b/Sensus.Shared/Probes/Context/LightProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
diff --git a/Sensus.Shared/Probes/Context/ListeningAmbientTemperatureProbe.cs b/Sensus.Shared/Probes/Context/ListeningAmbientTemperatureProbe.cs
index 5e1861d6e..e398515dc 100644
--- a/Sensus.Shared/Probes/Context/ListeningAmbientTemperatureProbe.cs
+++ b/Sensus.Shared/Probes/Context/ListeningAmbientTemperatureProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -95,4 +100,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Context/SoundDatum.cs b/Sensus.Shared/Probes/Context/SoundDatum.cs
index 12ce3eae7..cae0c6ad7 100644
--- a/Sensus.Shared/Probes/Context/SoundDatum.cs
+++ b/Sensus.Shared/Probes/Context/SoundDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
diff --git a/Sensus.Shared/Probes/Context/SoundProbe.cs b/Sensus.Shared/Probes/Context/SoundProbe.cs
index a6a9ad68b..a5c3b3b92 100644
--- a/Sensus.Shared/Probes/Context/SoundProbe.cs
+++ b/Sensus.Shared/Probes/Context/SoundProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Plugin.Permissions.Abstractions;
diff --git a/Sensus.Shared/Probes/DataRateCalculator.cs b/Sensus.Shared/Probes/DataRateCalculator.cs
index cc02145e4..46966f3fc 100644
--- a/Sensus.Shared/Probes/DataRateCalculator.cs
+++ b/Sensus.Shared/Probes/DataRateCalculator.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Exceptions;
@@ -214,4 +219,4 @@ public SamplingAction Add(Datum datum)
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Device/BatteryDatum.cs b/Sensus.Shared/Probes/Device/BatteryDatum.cs
index 5e1b32c91..4aed0ed2e 100644
--- a/Sensus.Shared/Probes/Device/BatteryDatum.cs
+++ b/Sensus.Shared/Probes/Device/BatteryDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
diff --git a/Sensus.Shared/Probes/Device/BatteryProbe.cs b/Sensus.Shared/Probes/Device/BatteryProbe.cs
index 00a3933a9..b7a457710 100644
--- a/Sensus.Shared/Probes/Device/BatteryProbe.cs
+++ b/Sensus.Shared/Probes/Device/BatteryProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.Generic;
diff --git a/Sensus.Shared/Probes/Device/ScreenDatum.cs b/Sensus.Shared/Probes/Device/ScreenDatum.cs
index 4e16d7f3c..9e77f8e6a 100644
--- a/Sensus.Shared/Probes/Device/ScreenDatum.cs
+++ b/Sensus.Shared/Probes/Device/ScreenDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus.Probes.User.Scripts.ProbeTriggerProperties;
using System;
diff --git a/Sensus.Shared/Probes/Device/ScreenProbe.cs b/Sensus.Shared/Probes/Device/ScreenProbe.cs
index d6a755aa5..f4cd32f1e 100644
--- a/Sensus.Shared/Probes/Device/ScreenProbe.cs
+++ b/Sensus.Shared/Probes/Device/ScreenProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Syncfusion.SfChart.XForms;
@@ -72,4 +77,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/ListeningProbe.cs b/Sensus.Shared/Probes/ListeningProbe.cs
index 33f7a4319..f4a75868b 100644
--- a/Sensus.Shared/Probes/ListeningProbe.cs
+++ b/Sensus.Shared/Probes/ListeningProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus.UI.UiProperties;
using System;
diff --git a/Sensus.Shared/Probes/Location/AltitudeDatum.cs b/Sensus.Shared/Probes/Location/AltitudeDatum.cs
index 4e809a150..fcecf6908 100644
--- a/Sensus.Shared/Probes/Location/AltitudeDatum.cs
+++ b/Sensus.Shared/Probes/Location/AltitudeDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Sensus.Probes.User.Scripts.ProbeTriggerProperties;
using System;
diff --git a/Sensus.Shared/Probes/Location/AltitudeProbe.cs b/Sensus.Shared/Probes/Location/AltitudeProbe.cs
index e06574d4d..88ccf34a8 100644
--- a/Sensus.Shared/Probes/Location/AltitudeProbe.cs
+++ b/Sensus.Shared/Probes/Location/AltitudeProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
diff --git a/Sensus.Shared/Probes/Location/CompassDatum.cs b/Sensus.Shared/Probes/Location/CompassDatum.cs
index 1a92c9ea6..42d58e27b 100644
--- a/Sensus.Shared/Probes/Location/CompassDatum.cs
+++ b/Sensus.Shared/Probes/Location/CompassDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
diff --git a/Sensus.Shared/Probes/Location/CompassProbe.cs b/Sensus.Shared/Probes/Location/CompassProbe.cs
index 1845dcd78..741e25077 100644
--- a/Sensus.Shared/Probes/Location/CompassProbe.cs
+++ b/Sensus.Shared/Probes/Location/CompassProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
diff --git a/Sensus.Shared/Probes/Location/EstimoteBeacon.cs b/Sensus.Shared/Probes/Location/EstimoteBeacon.cs
index 847916ca6..852f14ccf 100644
--- a/Sensus.Shared/Probes/Location/EstimoteBeacon.cs
+++ b/Sensus.Shared/Probes/Location/EstimoteBeacon.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -63,4 +68,4 @@ public override int GetHashCode()
return base.GetHashCode();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/EstimoteBeaconDatum.cs b/Sensus.Shared/Probes/Location/EstimoteBeaconDatum.cs
index beafee816..1883912cd 100644
--- a/Sensus.Shared/Probes/Location/EstimoteBeaconDatum.cs
+++ b/Sensus.Shared/Probes/Location/EstimoteBeaconDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Probes.User.Scripts.ProbeTriggerProperties;
@@ -106,4 +111,4 @@ public override string ToString()
"Proximity Event: " + ProximityEvent;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/EstimoteBeaconProbe.cs b/Sensus.Shared/Probes/Location/EstimoteBeaconProbe.cs
index d2fc44de2..cb2130c58 100644
--- a/Sensus.Shared/Probes/Location/EstimoteBeaconProbe.cs
+++ b/Sensus.Shared/Probes/Location/EstimoteBeaconProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.UI.UiProperties;
diff --git a/Sensus.Shared/Probes/Location/GpsReceiver.cs b/Sensus.Shared/Probes/Location/GpsReceiver.cs
index 95932bc2d..b9d461935 100644
--- a/Sensus.Shared/Probes/Location/GpsReceiver.cs
+++ b/Sensus.Shared/Probes/Location/GpsReceiver.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Linq;
@@ -227,4 +232,4 @@ public async Task GetReadingAsync(CancellationToken cancellationToken,
return reading;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/IPointsOfInterestProximityProbe.cs b/Sensus.Shared/Probes/Location/IPointsOfInterestProximityProbe.cs
index ff02ae0a3..16cfddda9 100644
--- a/Sensus.Shared/Probes/Location/IPointsOfInterestProximityProbe.cs
+++ b/Sensus.Shared/Probes/Location/IPointsOfInterestProximityProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Collections.ObjectModel;
@@ -23,4 +28,4 @@ public interface IPointsOfInterestProximityProbe
Protocol Protocol { get; }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/ListeningLocationProbe.cs b/Sensus.Shared/Probes/Location/ListeningLocationProbe.cs
index 3637a7643..e21949990 100644
--- a/Sensus.Shared/Probes/Location/ListeningLocationProbe.cs
+++ b/Sensus.Shared/Probes/Location/ListeningLocationProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
diff --git a/Sensus.Shared/Probes/Location/ListeningPointsOfInterestProximityProbe.cs b/Sensus.Shared/Probes/Location/ListeningPointsOfInterestProximityProbe.cs
index c89eba799..99c887420 100644
--- a/Sensus.Shared/Probes/Location/ListeningPointsOfInterestProximityProbe.cs
+++ b/Sensus.Shared/Probes/Location/ListeningPointsOfInterestProximityProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Linq;
@@ -161,4 +166,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
throw new NotImplementedException();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/LocationDatum.cs b/Sensus.Shared/Probes/Location/LocationDatum.cs
index f0c4efd4a..65d50de19 100644
--- a/Sensus.Shared/Probes/Location/LocationDatum.cs
+++ b/Sensus.Shared/Probes/Location/LocationDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
diff --git a/Sensus.Shared/Probes/Location/PointOfInterest.cs b/Sensus.Shared/Probes/Location/PointOfInterest.cs
index ebddee448..fde0aeadd 100644
--- a/Sensus.Shared/Probes/Location/PointOfInterest.cs
+++ b/Sensus.Shared/Probes/Location/PointOfInterest.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Probes.Movement;
@@ -94,4 +99,4 @@ public override string ToString()
return _name + (string.IsNullOrWhiteSpace(_type) ? "" : " (" + _type + ")") + ": " + Math.Round(_position.Latitude, 4) + "," + Math.Round(_position.Longitude, 4);
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/PointOfInterestProximityDatum.cs b/Sensus.Shared/Probes/Location/PointOfInterestProximityDatum.cs
index ec91aa2c2..755682001 100644
--- a/Sensus.Shared/Probes/Location/PointOfInterestProximityDatum.cs
+++ b/Sensus.Shared/Probes/Location/PointOfInterestProximityDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -177,4 +182,4 @@ public override string ToString()
"Trigger Direction: " + _triggerDistanceDirection;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/PointOfInterestProximityTrigger.cs b/Sensus.Shared/Probes/Location/PointOfInterestProximityTrigger.cs
index 0cd6b5f49..b9c08a332 100644
--- a/Sensus.Shared/Probes/Location/PointOfInterestProximityTrigger.cs
+++ b/Sensus.Shared/Probes/Location/PointOfInterestProximityTrigger.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -105,4 +110,4 @@ public override string ToString()
return _distanceThresholdDirection + " " + _distanceThresholdMeters + "m of " + _pointOfInterestName + (string.IsNullOrWhiteSpace(_pointOfInterestType) ? "" : " (" + _pointOfInterestType + ")");
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/PollingLocationProbe.cs b/Sensus.Shared/Probes/Location/PollingLocationProbe.cs
index 971e03297..5e7ce317c 100644
--- a/Sensus.Shared/Probes/Location/PollingLocationProbe.cs
+++ b/Sensus.Shared/Probes/Location/PollingLocationProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
@@ -107,4 +112,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/PollingPointsOfInterestProximityProbe.cs b/Sensus.Shared/Probes/Location/PollingPointsOfInterestProximityProbe.cs
index 861a0d483..24897a1e6 100644
--- a/Sensus.Shared/Probes/Location/PollingPointsOfInterestProximityProbe.cs
+++ b/Sensus.Shared/Probes/Location/PollingPointsOfInterestProximityProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Linq;
@@ -131,4 +136,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
throw new NotImplementedException();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/ProximityDatum.cs b/Sensus.Shared/Probes/Location/ProximityDatum.cs
index 6e951d5c4..a332839be 100644
--- a/Sensus.Shared/Probes/Location/ProximityDatum.cs
+++ b/Sensus.Shared/Probes/Location/ProximityDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -93,4 +98,4 @@ public override string ToString()
"Max. Distance: " + _maxDistance;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Location/ProximityProbe.cs b/Sensus.Shared/Probes/Location/ProximityProbe.cs
index f76dc173f..28ca394cf 100644
--- a/Sensus.Shared/Probes/Location/ProximityProbe.cs
+++ b/Sensus.Shared/Probes/Location/ProximityProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -81,4 +86,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
throw new NotImplementedException();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Movement/AccelerometerDatum.cs b/Sensus.Shared/Probes/Movement/AccelerometerDatum.cs
index 6b8a28e4c..fc5781c79 100644
--- a/Sensus.Shared/Probes/Movement/AccelerometerDatum.cs
+++ b/Sensus.Shared/Probes/Movement/AccelerometerDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
diff --git a/Sensus.Shared/Probes/Movement/AccelerometerProbe.cs b/Sensus.Shared/Probes/Movement/AccelerometerProbe.cs
index 9843a3b2a..c22ef7629 100644
--- a/Sensus.Shared/Probes/Movement/AccelerometerProbe.cs
+++ b/Sensus.Shared/Probes/Movement/AccelerometerProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
@@ -116,4 +121,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
throw new NotImplementedException();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Movement/ActivityDatum.cs b/Sensus.Shared/Probes/Movement/ActivityDatum.cs
index 30919db7d..3001ea178 100644
--- a/Sensus.Shared/Probes/Movement/ActivityDatum.cs
+++ b/Sensus.Shared/Probes/Movement/ActivityDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -153,4 +158,4 @@ public override string ToString()
"Confidence: " + Confidence;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Movement/GyroscopeDatum.cs b/Sensus.Shared/Probes/Movement/GyroscopeDatum.cs
index 6026d1f4e..c6f492ddb 100644
--- a/Sensus.Shared/Probes/Movement/GyroscopeDatum.cs
+++ b/Sensus.Shared/Probes/Movement/GyroscopeDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
diff --git a/Sensus.Shared/Probes/Movement/GyroscopeProbe.cs b/Sensus.Shared/Probes/Movement/GyroscopeProbe.cs
index 6a62d376c..1dc4dceab 100644
--- a/Sensus.Shared/Probes/Movement/GyroscopeProbe.cs
+++ b/Sensus.Shared/Probes/Movement/GyroscopeProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
@@ -82,4 +87,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
throw new NotImplementedException();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Movement/ListeningSpeedProbe.cs b/Sensus.Shared/Probes/Movement/ListeningSpeedProbe.cs
index 189174cdd..659be9a85 100644
--- a/Sensus.Shared/Probes/Movement/ListeningSpeedProbe.cs
+++ b/Sensus.Shared/Probes/Movement/ListeningSpeedProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Probes.Location;
@@ -170,4 +175,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Movement/PollingSpeedProbe.cs b/Sensus.Shared/Probes/Movement/PollingSpeedProbe.cs
index 74ad2bc1a..d8c625d8c 100644
--- a/Sensus.Shared/Probes/Movement/PollingSpeedProbe.cs
+++ b/Sensus.Shared/Probes/Movement/PollingSpeedProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
@@ -130,4 +135,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Movement/SpeedDatum.cs b/Sensus.Shared/Probes/Movement/SpeedDatum.cs
index c77946676..1e46314af 100644
--- a/Sensus.Shared/Probes/Movement/SpeedDatum.cs
+++ b/Sensus.Shared/Probes/Movement/SpeedDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
diff --git a/Sensus.Shared/Probes/Network/CellTowerDatum.cs b/Sensus.Shared/Probes/Network/CellTowerDatum.cs
index 9df22d789..c75d6d033 100644
--- a/Sensus.Shared/Probes/Network/CellTowerDatum.cs
+++ b/Sensus.Shared/Probes/Network/CellTowerDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Newtonsoft.Json;
using System;
diff --git a/Sensus.Shared/Probes/Network/CellTowerProbe.cs b/Sensus.Shared/Probes/Network/CellTowerProbe.cs
index 1b2bdca11..95fa5fe12 100644
--- a/Sensus.Shared/Probes/Network/CellTowerProbe.cs
+++ b/Sensus.Shared/Probes/Network/CellTowerProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
diff --git a/Sensus.Shared/Probes/Network/ListeningWlanProbe.cs b/Sensus.Shared/Probes/Network/ListeningWlanProbe.cs
index f7dd2bc3b..1d5c09354 100644
--- a/Sensus.Shared/Probes/Network/ListeningWlanProbe.cs
+++ b/Sensus.Shared/Probes/Network/ListeningWlanProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
diff --git a/Sensus.Shared/Probes/Network/PollingWlanProbe.cs b/Sensus.Shared/Probes/Network/PollingWlanProbe.cs
index 82fe06da0..a9cfcfb3c 100644
--- a/Sensus.Shared/Probes/Network/PollingWlanProbe.cs
+++ b/Sensus.Shared/Probes/Network/PollingWlanProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Syncfusion.SfChart.XForms;
@@ -60,4 +65,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
throw new NotImplementedException();
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Network/WlanDatum.cs b/Sensus.Shared/Probes/Network/WlanDatum.cs
index 95e29c1f7..79099dffe 100644
--- a/Sensus.Shared/Probes/Network/WlanDatum.cs
+++ b/Sensus.Shared/Probes/Network/WlanDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
diff --git a/Sensus.Shared/Probes/PollingProbe.cs b/Sensus.Shared/Probes/PollingProbe.cs
index 8d0b4b75f..c4dd4a9a8 100644
--- a/Sensus.Shared/Probes/PollingProbe.cs
+++ b/Sensus.Shared/Probes/PollingProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Linq;
@@ -492,4 +497,4 @@ public override async Task ResetAsync()
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/Probe.cs b/Sensus.Shared/Probes/Probe.cs
index 8b1373f14..231c00062 100644
--- a/Sensus.Shared/Probes/Probe.cs
+++ b/Sensus.Shared/Probes/Probe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Newtonsoft.Json;
using Sensus.UI.UiProperties;
@@ -675,4 +680,4 @@ public SfChart GetChart()
protected abstract ChartDataPoint GetChartDataPointFromDatum(Datum datum);
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/BiologicalSex.cs b/Sensus.Shared/Probes/User/Health/BiologicalSex.cs
index 84a58be6c..f6537ec1b 100644
--- a/Sensus.Shared/Probes/User/Health/BiologicalSex.cs
+++ b/Sensus.Shared/Probes/User/Health/BiologicalSex.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -22,4 +27,4 @@ public enum BiologicalSex
Male,
Other
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/BiologicalSexDatum.cs b/Sensus.Shared/Probes/User/Health/BiologicalSexDatum.cs
index 098bc8478..959f6dae9 100644
--- a/Sensus.Shared/Probes/User/Health/BiologicalSexDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/BiologicalSexDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -67,4 +72,4 @@ public override string ToString()
"Biological sex: " + _sex;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/BirthdateDatum.cs b/Sensus.Shared/Probes/User/Health/BirthdateDatum.cs
index 516a7c74b..82b255616 100644
--- a/Sensus.Shared/Probes/User/Health/BirthdateDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/BirthdateDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -64,4 +69,4 @@ public override string ToString()
"Birth date: " + _birthdate;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/BloodType.cs b/Sensus.Shared/Probes/User/Health/BloodType.cs
index 5a4121776..1964ea3cb 100644
--- a/Sensus.Shared/Probes/User/Health/BloodType.cs
+++ b/Sensus.Shared/Probes/User/Health/BloodType.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.User.Health
{
@@ -25,4 +30,4 @@ public enum BloodType
ONegative,
OPositive
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/BloodTypeDatum.cs b/Sensus.Shared/Probes/User/Health/BloodTypeDatum.cs
index a790d6f9c..09087edfd 100644
--- a/Sensus.Shared/Probes/User/Health/BloodTypeDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/BloodTypeDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -67,4 +72,4 @@ public override string ToString()
"Blood type: " + _bloodType;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/BodyMassIndexDatum.cs b/Sensus.Shared/Probes/User/Health/BodyMassIndexDatum.cs
index a3f2e5984..217d5cbc6 100644
--- a/Sensus.Shared/Probes/User/Health/BodyMassIndexDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/BodyMassIndexDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -69,4 +74,4 @@ public override string ToString()
"Body Mass Index: " + _bodyMassIndex;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/DistanceWalkingRunningDatum.cs b/Sensus.Shared/Probes/User/Health/DistanceWalkingRunningDatum.cs
index 7071361e7..9869f3c56 100644
--- a/Sensus.Shared/Probes/User/Health/DistanceWalkingRunningDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/DistanceWalkingRunningDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -69,4 +74,4 @@ public override string ToString()
"Distance Walking/Running (Miles): " + _distanceWalkingRunning;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/FitzpatrickSkinType.cs b/Sensus.Shared/Probes/User/Health/FitzpatrickSkinType.cs
index 48d8cc113..8b4d1106b 100644
--- a/Sensus.Shared/Probes/User/Health/FitzpatrickSkinType.cs
+++ b/Sensus.Shared/Probes/User/Health/FitzpatrickSkinType.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.User.Health
{
@@ -24,4 +29,4 @@ public enum FitzpatrickSkinType
TypeV,
TypeVI
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/FitzpatrickSkinTypeDatum.cs b/Sensus.Shared/Probes/User/Health/FitzpatrickSkinTypeDatum.cs
index e4ce21833..be3dcd3a8 100644
--- a/Sensus.Shared/Probes/User/Health/FitzpatrickSkinTypeDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/FitzpatrickSkinTypeDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -67,4 +72,4 @@ public override string ToString()
"Fitzpatrick Skin Type: " + _fitzPatrickSkinType;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/FlightsClimbedDatum.cs b/Sensus.Shared/Probes/User/Health/FlightsClimbedDatum.cs
index 3e8a43a22..b720d4f21 100644
--- a/Sensus.Shared/Probes/User/Health/FlightsClimbedDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/FlightsClimbedDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -69,4 +74,4 @@ public override string ToString()
"Flights Climbed (Floors): " + _flightsClimbed;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/HeartRateDatum.cs b/Sensus.Shared/Probes/User/Health/HeartRateDatum.cs
index da80f84e3..c9dc56ea0 100644
--- a/Sensus.Shared/Probes/User/Health/HeartRateDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/HeartRateDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -69,4 +74,4 @@ public override string ToString()
"Heart Rate (BPM): " + _heartRate;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/HeightDatum.cs b/Sensus.Shared/Probes/User/Health/HeightDatum.cs
index 5df5948f7..fda8f7151 100644
--- a/Sensus.Shared/Probes/User/Health/HeightDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/HeightDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -69,4 +74,4 @@ public override string ToString()
"Height (Inches): " + _heightInches;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/NumberOfTimesFallenDatum.cs b/Sensus.Shared/Probes/User/Health/NumberOfTimesFallenDatum.cs
index 21cac14d7..b5e248e57 100644
--- a/Sensus.Shared/Probes/User/Health/NumberOfTimesFallenDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/NumberOfTimesFallenDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -69,4 +74,4 @@ public override string ToString()
"Number of Times Fallen: " + _numberOfTimesFallen;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/StepCountDatum.cs b/Sensus.Shared/Probes/User/Health/StepCountDatum.cs
index 2c158e0cf..bb53dad60 100644
--- a/Sensus.Shared/Probes/User/Health/StepCountDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/StepCountDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -69,4 +74,4 @@ public override string ToString()
"Step Count: " + _stepCount;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/WeightDatum.cs b/Sensus.Shared/Probes/User/Health/WeightDatum.cs
index b27636a83..eb3d4b502 100644
--- a/Sensus.Shared/Probes/User/Health/WeightDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/WeightDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -69,4 +74,4 @@ public override string ToString()
"Weight (Pounds): " + _weightPounds;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Health/WheelchairUse.cs b/Sensus.Shared/Probes/User/Health/WheelchairUse.cs
index 8cde43941..15b120bb9 100644
--- a/Sensus.Shared/Probes/User/Health/WheelchairUse.cs
+++ b/Sensus.Shared/Probes/User/Health/WheelchairUse.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.User.Health
{
diff --git a/Sensus.Shared/Probes/User/Health/WheelchairUseDatum.cs b/Sensus.Shared/Probes/User/Health/WheelchairUseDatum.cs
index f255c9cb1..b5d84f4ea 100644
--- a/Sensus.Shared/Probes/User/Health/WheelchairUseDatum.cs
+++ b/Sensus.Shared/Probes/User/Health/WheelchairUseDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Newtonsoft.Json;
@@ -67,4 +72,4 @@ public override string ToString()
"Wheelchair Use: " + _wheelChairUse;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAccelerometerDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAccelerometerDatum.cs
index 2411c2f5e..2c563b406 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAccelerometerDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAccelerometerDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -113,4 +118,4 @@ public override string ToString()
"Z: " + _z;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAccelerometerProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAccelerometerProbe.cs
index edb71e23e..a9871a281 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAccelerometerProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAccelerometerProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -62,4 +67,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
return null;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirPressureDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirPressureDatum.cs
index 25534bb5b..1c9535382 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirPressureDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirPressureDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -77,4 +82,4 @@ public override string ToString()
"Air Pressure: " + _airPressure;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirPressureProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirPressureProbe.cs
index 30d8a63dd..9226f8a53 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirPressureProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirPressureProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -68,4 +73,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirTemperatureDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirTemperatureDatum.cs
index 0001c0dc0..26dd89c76 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirTemperatureDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirTemperatureDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -77,4 +82,4 @@ public override string ToString()
"Temperature: " + _temperature;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirTempreatureProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirTempreatureProbe.cs
index c33eb5057..7819f4808 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirTempreatureProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandAirTempreatureProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -68,4 +73,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandCaloriesDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandCaloriesDatum.cs
index eb619f6a9..e06191c2c 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandCaloriesDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandCaloriesDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -77,4 +82,4 @@ public override string ToString()
"Calories: " + _calories;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandCaloriesProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandCaloriesProbe.cs
index 062daf226..0c718218c 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandCaloriesProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandCaloriesProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -68,4 +73,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandClientConnectException.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandClientConnectException.cs
index 55faf54fc..8cc31c669 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandClientConnectException.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandClientConnectException.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
@@ -23,4 +28,4 @@ public MicrosoftBandClientConnectException(string message)
{
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandContactDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandContactDatum.cs
index 20a848a6c..0b465ecbb 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandContactDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandContactDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable.Sensors;
@@ -76,4 +81,4 @@ public override string ToString()
"State: " + _state;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandContactProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandContactProbe.cs
index e052c834f..3f323a4a6 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandContactProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandContactProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -87,4 +92,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
return null;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandDistanceDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandDistanceDatum.cs
index 2987e99ef..8ef5f7bae 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandDistanceDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandDistanceDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable.Sensors;
@@ -97,4 +102,4 @@ public override string ToString()
"Motion Type: " + _motionType;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandDistanceProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandDistanceProbe.cs
index bd3729782..ab4cff50e 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandDistanceProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandDistanceProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -68,4 +73,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGsrDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGsrDatum.cs
index 98683e0a9..cf844e161 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGsrDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGsrDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -77,4 +82,4 @@ public override string ToString()
"Resistance: " + _resistance;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGsrProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGsrProbe.cs
index 340d8e159..a483e5a44 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGsrProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGsrProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -68,4 +73,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGyroscopeDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGyroscopeDatum.cs
index 6127105cc..fbc4e101e 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGyroscopeDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGyroscopeDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -113,4 +118,4 @@ public override string ToString()
"Angular Z: " + _angularZ;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGyroscopeProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGyroscopeProbe.cs
index f000fe2ee..9c74c5689 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGyroscopeProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandGyroscopeProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -62,4 +67,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
return null;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandHeartRateDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandHeartRateDatum.cs
index 06685701c..037b28f6c 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandHeartRateDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandHeartRateDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -77,4 +82,4 @@ public override string ToString()
"Heart Rate: " + _heartRate;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandHeartRateProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandHeartRateProbe.cs
index a5f09bd51..c52889d32 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandHeartRateProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandHeartRateProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
@@ -88,4 +93,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandLightDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandLightDatum.cs
index e4d6ad05f..3ae5cc753 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandLightDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandLightDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -77,4 +82,4 @@ public override string ToString()
"Brightness: " + _brightness;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandLightProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandLightProbe.cs
index d29075a01..9da7ac026 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandLightProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandLightProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -68,4 +73,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandPedometerDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandPedometerDatum.cs
index 02fa07323..dd284c535 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandPedometerDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandPedometerDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -75,4 +80,4 @@ public override string ToString()
"Total Steps: " + _totalSteps;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandPedometerProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandPedometerProbe.cs
index 66e6947f4..b08839dfe 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandPedometerProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandPedometerProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -68,4 +73,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandProbe.cs
index 924302a42..9a57a4e70 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -110,4 +115,4 @@ protected override async Task StopReadingsAsync()
}
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandProbeBase.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandProbeBase.cs
index c7d6e5520..a63f5544f 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandProbeBase.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandProbeBase.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using Newtonsoft.Json;
using Microsoft.Band.Portable;
@@ -455,4 +460,4 @@ protected override ChartAxis GetChartPrimaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandRRIntervalDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandRRIntervalDatum.cs
index c85634338..5ffe889ad 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandRRIntervalDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandRRIntervalDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -77,4 +82,4 @@ public override string ToString()
"Interval: " + _interval;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandRRIntervalProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandRRIntervalProbe.cs
index e59a95296..945da6c87 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandRRIntervalProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandRRIntervalProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Threading;
@@ -88,4 +93,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandSkinTemperatureDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandSkinTemperatureDatum.cs
index 03c1f7074..8e43f33ab 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandSkinTemperatureDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandSkinTemperatureDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -77,4 +82,4 @@ public override string ToString()
"Temperature: " + _temperature;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandSkinTemperatureProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandSkinTemperatureProbe.cs
index 35d9940a3..410632faf 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandSkinTemperatureProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandSkinTemperatureProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -68,4 +73,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandStepDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandStepDatum.cs
index 5626cab86..484668e9e 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandStepDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandStepDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Sensus.Anonymization;
@@ -77,4 +82,4 @@ public override string ToString()
"Steps Ascended: " + _stepsAscended;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandStepProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandStepProbe.cs
index 9b0feebf3..28830eb6d 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandStepProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandStepProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -68,4 +73,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
};
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandUltravioletLightDatum.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandUltravioletLightDatum.cs
index 6a6f6ab43..6f69e3d0b 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandUltravioletLightDatum.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandUltravioletLightDatum.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable.Sensors;
@@ -76,4 +81,4 @@ public override string ToString()
"Level: " + _level;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandUltravioletLightProbe.cs b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandUltravioletLightProbe.cs
index 75391ea77..9760e3c16 100644
--- a/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandUltravioletLightProbe.cs
+++ b/Sensus.Shared/Probes/User/MicrosoftBand/MicrosoftBandUltravioletLightProbe.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using Microsoft.Band.Portable;
@@ -62,4 +67,4 @@ protected override RangeAxisBase GetChartSecondaryAxis()
return null;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/BooleanProbeTriggerProperty.cs b/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/BooleanProbeTriggerProperty.cs
index acfb344e7..098746781 100644
--- a/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/BooleanProbeTriggerProperty.cs
+++ b/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/BooleanProbeTriggerProperty.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.User.Scripts.ProbeTriggerProperties
{
diff --git a/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/DoubleProbeTriggerProperty.cs b/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/DoubleProbeTriggerProperty.cs
index a681cdf8a..8c838a43f 100644
--- a/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/DoubleProbeTriggerProperty.cs
+++ b/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/DoubleProbeTriggerProperty.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.User.Scripts.ProbeTriggerProperties
{
@@ -26,4 +31,4 @@ public DoubleProbeTriggerProperty(string name)
{
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/ListProbeTriggerProperty.cs b/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/ListProbeTriggerProperty.cs
index 1210adade..63dadba3f 100644
--- a/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/ListProbeTriggerProperty.cs
+++ b/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/ListProbeTriggerProperty.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.User.Scripts.ProbeTriggerProperties
{
@@ -35,4 +40,4 @@ public ListProbeTriggerProperty(string name, object[] items)
_items = items;
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/ProbeTriggerProperty.cs b/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/ProbeTriggerProperty.cs
index d8aaa897d..adeefe334 100644
--- a/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/ProbeTriggerProperty.cs
+++ b/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/ProbeTriggerProperty.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
diff --git a/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/StringProbeTriggerProperty.cs b/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/StringProbeTriggerProperty.cs
index d2bdcce84..e60babbe5 100644
--- a/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/StringProbeTriggerProperty.cs
+++ b/Sensus.Shared/Probes/User/Scripts/ProbeTriggerProperties/StringProbeTriggerProperty.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.User.Scripts.ProbeTriggerProperties
{
@@ -21,4 +26,4 @@ public StringProbeTriggerProperty() { }
public StringProbeTriggerProperty(string name): base(name)
{ }
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Scripts/RunMode.cs b/Sensus.Shared/Probes/User/Scripts/RunMode.cs
index a15f79bca..e25a46536 100644
--- a/Sensus.Shared/Probes/User/Scripts/RunMode.cs
+++ b/Sensus.Shared/Probes/User/Scripts/RunMode.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
namespace Sensus.Probes.User.Scripts
{
diff --git a/Sensus.Shared/Probes/User/Scripts/ScheduleTrigger.cs b/Sensus.Shared/Probes/User/Scripts/ScheduleTrigger.cs
index 73f38e05b..03e436ae1 100644
--- a/Sensus.Shared/Probes/User/Scripts/ScheduleTrigger.cs
+++ b/Sensus.Shared/Probes/User/Scripts/ScheduleTrigger.cs
@@ -1,16 +1,21 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
+//Copyright 2014 The Rector & Visitors of the University of Virginia
//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
//
-// http://www.apache.org/licenses/LICENSE-2.0
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
using System;
using System.Linq;
@@ -38,21 +43,21 @@ public string WindowsString
set
{
if (value == WindowsString)
- {
+ {
return;
}
lock (_windows)
- {
- _windows.Clear();
-
- try
+ {
+ _windows.Clear();
+
+ try
{
- _windows.AddRange(value.Split(new[] { ',' }, StringSplitOptions.RemoveEmptyEntries).Select(windowString => new TriggerWindow(windowString)));
- }
- catch
- {
- // ignore improperly formatted trigger windows
+ _windows.AddRange(value.Split(new[] { ',' }, StringSplitOptions.RemoveEmptyEntries).Select(windowString => new TriggerWindow(windowString)));
+ }
+ catch
+ {
+ // ignore improperly formatted trigger windows
}
_windows.Sort();
@@ -60,8 +65,8 @@ public string WindowsString
}
}
- public int NonDowTriggerIntervalDays
- {
+ public int NonDowTriggerIntervalDays
+ {
get
{
return _nonDowTriggerIntervalDays;
@@ -101,7 +106,7 @@ public string ReadableDescription
public ScheduleTrigger()
{
_windows = new List();
- _nonDowTriggerIntervalDays = 1;
+ _nonDowTriggerIntervalDays = 1;
}
///
@@ -113,7 +118,7 @@ public ScheduleTrigger()
/// Maximum age of the triggers, during which they should be valid.
public List GetTriggerTimes(DateTime startDate, TimeSpan? maxAge = null)
{
- lock (_windows)
+ lock (_windows)
{
// we used to use a yield-return approach for returning the trigger times; however, there's an issue: the reference time does not
// change, and if there are significant latencies involved in scheduling the returned trigger time then the notification time will
@@ -135,22 +140,22 @@ public List GetTriggerTimes(DateTime startDate, TimeSpan? max
// an opportunity to schedule additional surveys.
int numDays = Math.Max(10, _nonDowTriggerIntervalDays);
- for (int dayOffset = 0; dayOffset < numDays; ++dayOffset)
+ for (int dayOffset = 0; dayOffset < numDays; ++dayOffset)
{
DateTime triggerDate = startDate.AddDays(dayOffset);
DayOfWeek triggerDateDOW = triggerDate.DayOfWeek;
// schedule each window for the current date as necessary
foreach (TriggerWindow window in _windows)
- {
+ {
bool scheduleWindowForCurrentDate = false;
-
+
if (window.DayOfTheWeek.HasValue)
{
if (window.DayOfTheWeek.Value == triggerDateDOW)
- {
+ {
scheduleWindowForCurrentDate = true;
- }
+ }
}
// we need a reference point for calculating the day-based interval. the minimum value will work.
else if ((triggerDate - DateTime.MinValue).Days % _nonDowTriggerIntervalDays == 0)
@@ -159,17 +164,17 @@ public List GetTriggerTimes(DateTime startDate, TimeSpan? max
}
if (scheduleWindowForCurrentDate)
- {
- ScriptTriggerTime triggerTime = window.GetNextTriggerTime(triggerDate, WindowExpiration, maxAge);
+ {
+ ScriptTriggerTime triggerTime = window.GetNextTriggerTime(triggerDate, WindowExpiration, maxAge);
triggerTimes.Add(triggerTime);
}
- }
+ }
}
triggerTimes.Sort((x, y) => x.Trigger.CompareTo(y.Trigger));
- return triggerTimes;
- }
+ return triggerTimes;
+ }
}
}
-}
\ No newline at end of file
+}
diff --git a/Sensus.Shared/Probes/User/Scripts/Script.cs b/Sensus.Shared/Probes/User/Scripts/Script.cs
index d42ea47ae..becab1607 100644
--- a/Sensus.Shared/Probes/User/Scripts/Script.cs
+++ b/Sensus.Shared/Probes/User/Scripts/Script.cs
@@ -1,213 +1,218 @@
-// Copyright 2014 The Rector & Visitors of the University of Virginia
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-using System;
-using System.Linq;
-using System.Collections.ObjectModel;
-using Newtonsoft.Json;
-using Sensus.UI.Inputs;
-using System.ComponentModel;
-using Newtonsoft.Json.Serialization;
+//Copyright 2014 The Rector & Visitors of the University of Virginia
+//
+//Permission is hereby granted, free of charge, to any person obtaining a copy
+//of this software and associated documentation files (the "Software"), to deal
+//in the Software without restriction, including without limitation the rights
+//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+//copies of the Software, and to permit persons to whom the Software is
+//furnished to do so, subject to the following conditions:
+//
+//The above copyright notice and this permission notice shall be included in
+//all copies or substantial portions of the Software.
+//
+//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
+//INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
+//PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+//HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+//OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+//SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+using System;
+using System.Linq;
+using System.Collections.ObjectModel;
+using Newtonsoft.Json;
+using Sensus.UI.Inputs;
+using System.ComponentModel;
+using Newtonsoft.Json.Serialization;
using System.Collections.Generic;
-namespace Sensus.Probes.User.Scripts
-{
- public class Script : INotifyPropertyChanged, IComparable