Sales/Program.cs
author Markus Bröker<broeker.markus@googlemail.com>
Wed, 29 Mar 2017 12:48:46 +0200
changeset 2 0907765a8b2e
parent 1 80c685d55d63
permissions -rwxr-xr-x
Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
     1
/**
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
     2
 * Program.cs
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
     3
 * 
2
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
     4
* 
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
     5
 * The MIT License (MIT)
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
     6
 *
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
     7
 * @copyright Copyright(C) 2017 4Customers UG
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
     8
 * @author    Markus Bröker<broeker.markus@googlemail.com>
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
     9
 *
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    10
 * Permission is hereby granted, free of charge, to any person obtaining a copy
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    11
 * of this software and associated documentation files (the "Software"), to deal
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    12
 * in the Software without restriction, including without limitation the rights
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    13
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    14
 * copies of the Software, and to permit persons to whom the Software is
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    15
 * furnished to do so, subject to the following conditions:
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    16
 *
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    17
 * The above copyright notice and this permission notice shall be included in all
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    18
 * copies or substantial portions of the Software.
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    19
 *
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    20
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    21
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    22
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    23
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    24
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    25
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
0907765a8b2e Visual Studio / Xamarin Studio Lizenzbedingungen beachten
Markus Bröker<broeker.markus@googlemail.com>
parents: 1
diff changeset
    26
 * SOFTWARE.
0
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    27
 */
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    28
using System;
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    29
using System.Collections.Generic;
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    30
using System.Linq;
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    31
using System.Text;
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    32
using System.Threading.Tasks;
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    33
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    34
using static Sales.Payment;
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    35
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    36
namespace Sales
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    37
{
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    38
    class Program
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    39
    {
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    40
        static void Main(string[] args)
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    41
        {
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    42
            Console.OutputEncoding = Encoding.Default;
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    43
1
80c685d55d63 Sinnvolles Beispiel für Function-Pointer in C#
Markus Bröker<broeker.markus@googlemail.com>
parents: 0
diff changeset
    44
            Invoice invoice = new Sales.Invoice(599.99, PaymentType.LATER);
80c685d55d63 Sinnvolles Beispiel für Function-Pointer in C#
Markus Bröker<broeker.markus@googlemail.com>
parents: 0
diff changeset
    45
            Console.WriteLine("Die Endsumme beträgt {0:C}", invoice.getFinalResult());		           
0
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    46
        }
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    47
    }
cfa10fbf52b3 Initialer Commit
Markus Bröker<mbroeker@4customers.de>
parents:
diff changeset
    48
}