parametr argument, C#/Parametr, Visual Studio 2022

This commit is contained in:
Lukáš Kaňka 2023-08-31 22:34:36 +02:00
parent 73802285dd
commit be2640307c
33 changed files with 311 additions and 0 deletions

Binary file not shown.

Binary file not shown.

25
C#/Parametr/Parametr.sln Normal file
View File

@ -0,0 +1,25 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.7.34018.315
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Parametr", "Parametr\Parametr.csproj", "{5E2AA941-2323-4E74-B153-1CACAF3B3A75}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{5E2AA941-2323-4E74-B153-1CACAF3B3A75}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5E2AA941-2323-4E74-B153-1CACAF3B3A75}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5E2AA941-2323-4E74-B153-1CACAF3B3A75}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5E2AA941-2323-4E74-B153-1CACAF3B3A75}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {80BCD470-0C2D-4AF7-BE2E-22A971A0CF1B}
EndGlobalSection
EndGlobal

View File

@ -0,0 +1,25 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Parametr
{
public class NamedArgument
{
public static void Main(string[] args)
{
PrintEmployeeDetail("Franta", 12, 2015);
PrintEmployeeDetail(age: 34, name: "Karel", empid: 2345); // tímto způsobem nemusíme dodržovat pořadí argumentů
}
static void PrintEmployeeDetail(string name, int age, int empid)
{
Console.WriteLine($"Name : {name}, Age : {age}, Employee ID : {empid}");
}
}
}

View File

@ -0,0 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net6.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
</Project>

View File

@ -0,0 +1,23 @@
{
"runtimeTarget": {
"name": ".NETCoreApp,Version=v6.0",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETCoreApp,Version=v6.0": {
"Parametr/1.0.0": {
"runtime": {
"Parametr.dll": {}
}
}
}
},
"libraries": {
"Parametr/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
}
}
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,9 @@
{
"runtimeOptions": {
"tfm": "net6.0",
"framework": {
"name": "Microsoft.NETCore.App",
"version": "6.0.0"
}
}
}

View File

@ -0,0 +1,4 @@
// <autogenerated />
using System;
using System.Reflection;
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v6.0", FrameworkDisplayName = ".NET 6.0")]

View File

@ -0,0 +1,23 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using System;
using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("Parametr")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")]
[assembly: System.Reflection.AssemblyProductAttribute("Parametr")]
[assembly: System.Reflection.AssemblyTitleAttribute("Parametr")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
// Generated by the MSBuild WriteCodeFragment class.

View File

@ -0,0 +1 @@
bd8b1481e8d10defa10ae51d57edd34df0bf7c97

View File

@ -0,0 +1,11 @@
is_global = true
build_property.TargetFramework = net6.0
build_property.TargetPlatformMinVersion =
build_property.UsingMicrosoftNETSdkWeb =
build_property.ProjectTypeGuids =
build_property.InvariantGlobalization =
build_property.PlatformNeutralAssembly =
build_property.EnforceExtendedAnalyzerRules =
build_property._SupportedPlatformList = Linux,macOS,Windows
build_property.RootNamespace = Parametr
build_property.ProjectDir = C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\

View File

@ -0,0 +1,8 @@
// <auto-generated/>
global using global::System;
global using global::System.Collections.Generic;
global using global::System.IO;
global using global::System.Linq;
global using global::System.Net.Http;
global using global::System.Threading;
global using global::System.Threading.Tasks;

View File

@ -0,0 +1 @@
fd0a288330aca4b901a1aff763a085c2feee07d8

View File

@ -0,0 +1,14 @@
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\obj\Debug\net6.0\Parametr.GeneratedMSBuildEditorConfig.editorconfig
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\obj\Debug\net6.0\Parametr.AssemblyInfoInputs.cache
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\obj\Debug\net6.0\Parametr.AssemblyInfo.cs
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\obj\Debug\net6.0\Parametr.csproj.CoreCompileInputs.cache
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\bin\Debug\net6.0\Parametr.exe
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\bin\Debug\net6.0\Parametr.deps.json
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\bin\Debug\net6.0\Parametr.runtimeconfig.json
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\bin\Debug\net6.0\Parametr.dll
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\bin\Debug\net6.0\Parametr.pdb
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\obj\Debug\net6.0\Parametr.dll
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\obj\Debug\net6.0\refint\Parametr.dll
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\obj\Debug\net6.0\Parametr.pdb
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\obj\Debug\net6.0\Parametr.genruntimeconfig.cache
C:\Users\lukas\Nextcloud\GitHub\.Net_C.Sharp_Test\C#\Parametr\Parametr\obj\Debug\net6.0\ref\Parametr.dll

Binary file not shown.

View File

@ -0,0 +1 @@
a056352bc70140a5bdca0996bcf0538a89a925fb

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,63 @@
{
"format": 1,
"restore": {
"C:\\Users\\lukas\\Nextcloud\\GitHub\\.Net_C.Sharp_Test\\C#\\Parametr\\Parametr\\Parametr.csproj": {}
},
"projects": {
"C:\\Users\\lukas\\Nextcloud\\GitHub\\.Net_C.Sharp_Test\\C#\\Parametr\\Parametr\\Parametr.csproj": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "C:\\Users\\lukas\\Nextcloud\\GitHub\\.Net_C.Sharp_Test\\C#\\Parametr\\Parametr\\Parametr.csproj",
"projectName": "Parametr",
"projectPath": "C:\\Users\\lukas\\Nextcloud\\GitHub\\.Net_C.Sharp_Test\\C#\\Parametr\\Parametr\\Parametr.csproj",
"packagesPath": "C:\\Users\\lukas\\.nuget\\packages\\",
"outputPath": "C:\\Users\\lukas\\Nextcloud\\GitHub\\.Net_C.Sharp_Test\\C#\\Parametr\\Parametr\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\lukas\\AppData\\Roaming\\NuGet\\NuGet.Config",
"C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config"
],
"originalTargetFrameworks": [
"net6.0"
],
"sources": {
"C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {},
"https://api.nuget.org/v3/index.json": {}
},
"frameworks": {
"net6.0": {
"targetAlias": "net6.0",
"projectReferences": {}
}
},
"warningProperties": {
"warnAsError": [
"NU1605"
]
}
},
"frameworks": {
"net6.0": {
"targetAlias": "net6.0",
"imports": [
"net461",
"net462",
"net47",
"net471",
"net472",
"net48",
"net481"
],
"assetTargetFallback": true,
"warn": true,
"frameworkReferences": {
"Microsoft.NETCore.App": {
"privateAssets": "all"
}
},
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\7.0.400\\RuntimeIdentifierGraph.json"
}
}
}
}
}

View File

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<RestoreSuccess Condition=" '$(RestoreSuccess)' == '' ">True</RestoreSuccess>
<RestoreTool Condition=" '$(RestoreTool)' == '' ">NuGet</RestoreTool>
<ProjectAssetsFile Condition=" '$(ProjectAssetsFile)' == '' ">$(MSBuildThisFileDirectory)project.assets.json</ProjectAssetsFile>
<NuGetPackageRoot Condition=" '$(NuGetPackageRoot)' == '' ">$(UserProfile)\.nuget\packages\</NuGetPackageRoot>
<NuGetPackageFolders Condition=" '$(NuGetPackageFolders)' == '' ">C:\Users\lukas\.nuget\packages\</NuGetPackageFolders>
<NuGetProjectStyle Condition=" '$(NuGetProjectStyle)' == '' ">PackageReference</NuGetProjectStyle>
<NuGetToolVersion Condition=" '$(NuGetToolVersion)' == '' ">6.7.0</NuGetToolVersion>
</PropertyGroup>
<ItemGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<SourceRoot Include="C:\Users\lukas\.nuget\packages\" />
</ItemGroup>
</Project>

View File

@ -0,0 +1,2 @@
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" />

View File

@ -0,0 +1,68 @@
{
"version": 3,
"targets": {
"net6.0": {}
},
"libraries": {},
"projectFileDependencyGroups": {
"net6.0": []
},
"packageFolders": {
"C:\\Users\\lukas\\.nuget\\packages\\": {}
},
"project": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "C:\\Users\\lukas\\Nextcloud\\GitHub\\.Net_C.Sharp_Test\\C#\\Parametr\\Parametr\\Parametr.csproj",
"projectName": "Parametr",
"projectPath": "C:\\Users\\lukas\\Nextcloud\\GitHub\\.Net_C.Sharp_Test\\C#\\Parametr\\Parametr\\Parametr.csproj",
"packagesPath": "C:\\Users\\lukas\\.nuget\\packages\\",
"outputPath": "C:\\Users\\lukas\\Nextcloud\\GitHub\\.Net_C.Sharp_Test\\C#\\Parametr\\Parametr\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\lukas\\AppData\\Roaming\\NuGet\\NuGet.Config",
"C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config"
],
"originalTargetFrameworks": [
"net6.0"
],
"sources": {
"C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {},
"https://api.nuget.org/v3/index.json": {}
},
"frameworks": {
"net6.0": {
"targetAlias": "net6.0",
"projectReferences": {}
}
},
"warningProperties": {
"warnAsError": [
"NU1605"
]
}
},
"frameworks": {
"net6.0": {
"targetAlias": "net6.0",
"imports": [
"net461",
"net462",
"net47",
"net471",
"net472",
"net48",
"net481"
],
"assetTargetFallback": true,
"warn": true,
"frameworkReferences": {
"Microsoft.NETCore.App": {
"privateAssets": "all"
}
},
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\7.0.400\\RuntimeIdentifierGraph.json"
}
}
}
}

View File

@ -0,0 +1,8 @@
{
"version": 2,
"dgSpecHash": "ItIvtNWftMT9BjmjG0tKuYCeLUo9TQrhFu6LT1vlJMyneXEnDlWJB9FTfu6ZhZUy3mmTw2p5Lkw6vbkVO8z9UA==",
"success": true,
"projectFilePath": "C:\\Users\\lukas\\Nextcloud\\GitHub\\.Net_C.Sharp_Test\\C#\\Parametr\\Parametr\\Parametr.csproj",
"expectedPackageFiles": [],
"logs": []
}