예제 #1
0
 protected virtual BeaconRegion FromNative(EstimoteSdk.Observation.Region.Beacon.BeaconRegion native)
 {
     return(new BeaconRegion(
                native.Identifier,
                native.ProximityUUID.ToString(),
                (ushort?)native.Major,
                (ushort?)native.Minor
                ));
 }
예제 #2
0
        protected virtual EstimoteSdk.Observation.Region.Beacon.BeaconRegion ToNative(BeaconRegion region)
        {
            EstimoteSdk.Observation.Region.Beacon.BeaconRegion native = null;

            if (region.Major > 0 && region.Minor > 0)
            {
                native = new EstimoteSdk.Observation.Region.Beacon.BeaconRegion(region.Identifier, region.Uuid, region.Major.Value, region.Minor.Value);
            }

            else if (region.Major > 0)
            {
                native = new EstimoteSdk.Observation.Region.Beacon.BeaconRegion(region.Identifier, region.Uuid, region.Major.Value);
            }

            else
            {
                native = new EstimoteSdk.Observation.Region.Beacon.BeaconRegion(region.Identifier, region.Uuid);
            }

            return(native);
        }