Ejemplo n.º 1
0
        public bool BinarySerialize()
        {
            try
            {
                BinarySerialization <List <Customer> > .FileName = "MemberLista.DAT";
                BinarySerialization <List <Customer> > .BinarySerialize(customers);
            }
            catch (Exception)
            {
                throw;
            }

            return(true);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// BinarySerialize is a method in the MemberList class that
        /// Serialize (save object from the program into files) using
        /// binary serialization.
        /// </summary>
        /// <returns>true or cast an exception</returns>
        public bool BinarySerialize()
        {
            try
            {
                BinarySerialization <List <Kund> > .FileName = "KundLista.DAT";
                BinarySerialization <List <Kund> > .BinarySerialize(k_kundList);
            }
            catch (Exception ex)
            {
                throw new CustomException(ex.Message);
            }

            return(true);
        }
Ejemplo n.º 3
0
        public bool BinarySerialize()
        {
            try
            {
                BinarySerialization <List <Cabin> > .FileName = "CabinLista.DAT";
                BinarySerialization <List <Cabin> > .BinarySerialize(cabins);
            }
            catch (Exception)
            {
                throw;
            }

            return(true);
        }
Ejemplo n.º 4
0
        public bool BinarySerialize()
        {
            try
            {
                BinarySerialization <List <Booking> > .FileName = "BookingLista.DAT";
                BinarySerialization <List <Booking> > .BinarySerialize(bookings);
            }
            catch (Exception)
            {
                throw;
            }

            return(true);
        }
Ejemplo n.º 5
0
        public bool BinarySerialize()
        {
            try
            {
                BinarySerialization <List <Prices> > .FileName = "PrizeLista.DAT";
                BinarySerialization <List <Prices> > .BinarySerialize(prices);
            }
            catch (Exception)
            {
                throw;
            }

            return(true);
        }
Ejemplo n.º 6
0
        /// <summary>
        /// BinarySerialize is a method in the MemberList class that
        /// Serialize (save object from the program into files) using
        /// binary serialization.
        /// </summary>
        /// <returns>true or cast an exception</returns>
        public bool BinarySerialize()
        {
            try
            {
                BinarySerialization <List <Dykarkurs> > .FileName = "DykarkursLista.DAT";
                BinarySerialization <List <Dykarkurs> > .BinarySerialize(d_dykarkursList);
            }
            catch (Exception ex)
            {
                throw new CustomException(ex.Message);
            }

            return(true);
        }