﻿// Decompiled with JetBrains decompiler
// Type: Wb.Lpw.Platform.Protocol.GateReaderV1
// Assembly: Wb.Lpw.Protocol, Version=2.13.83.0, Culture=neutral, PublicKeyToken=null
// MVID: A621984F-C936-438B-B744-D121BF336087
// Assembly location: C:\Users\CGA Computer\Desktop\LEGO Universe Stuff\LOCO Server\Unity Web Player Extractor\Saved Files\LOCO Server.unity3d_unpacked\Wb.Lpw.Protocol.dll

using System;
using System.Collections.Generic;
using System.Globalization;
using System.Xml.Serialization;

namespace Wb.Lpw.Platform.Protocol
{
  [XmlRoot(ElementName = "Gate")]
  [Serializable]
  public class GateReaderV1 : GateReaderBase
  {
    [XmlElement(Order = 1)]
    public string version = "1.0";
    [XmlElement(Order = 2)]
    public ProductV1 Product = new ProductV1();

    public override ProductBase AddNewProduct()
    {
      if (this.Product != null)
        return (ProductBase) null;
      this.Product = new ProductV1();
      return (ProductBase) this.Product;
    }

    public override void RemoveProduct(ProductBase product)
    {
      if (this.Product != product)
        return;
      this.Product = (ProductV1) null;
    }

    public override List<ProductBase> GetProducts()
    {
      List<ProductBase> list = new List<ProductBase>();
      if (this.Product != null)
        list.Add((ProductBase) this.Product);
      return list;
    }

    public override double GetGateVersion()
    {
      return double.Parse(this.version, (IFormatProvider) CultureInfo.InvariantCulture);
    }
  }
}
