# ASP.NET이란?
ASP.NET은 동적 웹 사이트(웹 응용 프로그램)을 만들기 위한 마이크로소프트의 웹 개발 기술
ASP.NET은 .NET Framework에서만 동작
(ASP.NET 1.X는 .NET Framework 1.1에서 ASP.NET 2.0은 .NET Framework 2.0에서 동작합니다.)
ASP.NET을 구현할 수 있는 언어가 C#, VB, J#, C++ 등으로 나뉘어지기 때문에 ASP.NET은 웹 개발 기술
Web.config 등으로 사이트를 쉽게 관리할 수 있다.
Web.config 등으로 보안 기능인 인증(Authentication) / 권한 부여(Authorization) 를 쉽게할 수 있도록 도와준다.
Web.config 파일의 styleSheetTheme 속성에 테마 설정. 색상, 디자인 등을 각각 설정, 사이트 전체에 반영하는 방법
서버콘트롤을 상속받아 자신의 콘트롤을 만들어 서버콘트롤처럼 사용가능
언어독립적 협업 : 언어가 무엇이든 상관없는 것이 특징이다. 일부는 VB로 일부는 C#으로 구현하여 하나의 웹사이트로 동작시킬 수 있다.
안정된 웹 응용프로그램 작성 및 웹기반 다른언어(자바스크립트 라이브러리 등)과 호환 잘됨.
개발의 단순성 : 인터페이스를 서버콘트롤로 제공
개발 및 실행 시 발생될 수 있는 모든 문제에 대한 대처기능 제공되어있다.
# ASP, PHP, JSP란?
웹 스크립트 언어
# 프로젝트와 솔루션 개념
프로젝트(Project): 하나의 프로그램을 이루는 가장 작은 단위가 되는 프로그램을 말한다. 예를 들어 게시판 프로젝트, 방명록 프로젝트, 쇼핑몰 프로젝트 등 단위 프로그램 하나를 프로젝트라고 한다. Visual Studio에서 프로젝트는 확장자가 csproj(C# 프로젝트를 의미)인 파일로 관련된 여러 파일을 하나의 이름으로 묶는 역할을 한다.
• 솔루션(Solution): 프로젝트가 하나 이상 모여서 만들어진 프로그램을 말하며 Visual Studio에서 솔루션은 하나 이상의 프로젝트를 묶어서 하나의 단위로 표현할 때 사용된다. 예를 들어 프로젝트가 여러 개 모인 웹 사이트 솔루션, ERP 솔루션, 쇼핑몰 솔루션 등 완성된 프로그램 그룹 하나를 솔루션이라고 한다. Visual Studio에서 솔루션은 확장자가 sln(솔루션의 약자)인 파일로 하나 이상의 프로젝트를 묶어서 관리할 때 사용된다.
# ASP.NET 프로젝트 구조
Visual Studio 상에서, MVC 구조로 프로젝트를 생성할 경우, Models, Controllers, Views 라는 폴더구조로 자동 생성된다.
# 자동생성되는 폴더
- obj 폴더
The obj folder holds object, or intermediate, files, which are compiled binary files that haven't been linked yet. They're essentially fragments that will be combined to produce the final executable. The compiler generates one object file for each source file, and those files are placed into the obj folder.
obj 폴더는 아직 Link되지 않은 컴파일된 파이너리 파일들을 담고 있다. 컴파일러는 각각의 소스파일을 하나의 object 파일로 생성하며, 그러한 파일들은 object 폴더에 위치하게 된다. 해당 파일들은 최종 실행물을 만들기 위해서 결합될 것이다.
- bin 폴더
The bin folder holds binary files, which are the actual executable code for your application or library.
bin 폴더는 어플리케이션 또는 라이브러리의 실행가능한 코드들이 있는 바이너리 파일들을 담는다.
Each of these folders are further subdivided into Debug and Release folders, which simply correspond to the project's build configurations. The two types of files discussed above are placed into the appropriate folder, depending on which type of build you perform. This makes it easy for you to determine which executables are built with debugging symbols, and which were built with optimizations enabled and ready for release.
각각의 폴더는 Debug와 Release 폴더로 나뉘며, 프로젝트의 build 옵션에 따라 상응된다. release는 최적화에 초점을 맞추어 빌드되고, debug는 실행에 초점을 맞추어 빌드된다.
- Properties/AssemblyInfo.cs
Compiler 옵션을 설정해 놓은 파일
AssemblyInfo.cs file is a general C#.NET file. If we create any new C# project (i.e., .csproj) - We get this file generated. This contains the Assembly's properties. For example, version information, manufacturer and other such details. It could also contain the signing information, etc, if you are using such functionalities. These inputs will be taken by the compiler when you compile (during the build process) the application.
AssemblyInfo.cs 파일이란 C#.net 언어 형식의 파일로써, C# 프로젝트 생성시 자동으로 생성된다.
버전 정보, 제공자, 싸인 정보와 같은 부가 정보들을 속성으로 가지고 있으며, 그러한 입력값들을 해당 파일에 정의해 놓으면, 빌드 중 컴파일될 때, 이러한 Input 값들이 결과물에 Taken 된다.
Once the compilation is completed, it is all just about "[YourProjectName].dll" file (and any other referenced dlls) that matters. So, it is similar to other .cs files with in your application as far as the output is concerned. However, I'm not sure about what PublishProfiles folder of your application does (or if it was some generated folder during any publish features). But this basic idea of AssemblyInfo.cs should help you understand the concept behind it.
일단 컴파일이 완료되면, [프로젝트이름].dll 파일이 생성되고, 사용될 것이다.
Simple answer, you don't need this when your only concern is to publish the web application. However if you want to publish the assembly as a reusable component than it is advised to fill in those assembly properties.
단순히 웹 어플리케이션이면 AssemblyInfo.cs 파일이 필요하지 않다. 그러나, 재사용가능한 컴포넌트를 배포하기를 원한다면, 해당 파일에 assembly 속성들을 채우는 것을 권장한다.
# 출처
https://hackersstudy.tistory.com/45 [공대인들이 직접쓰는 컴퓨터공부방]
'[DEV] App Dev ∕ Web Front > Framework ∕ Asp.Net' 카테고리의 다른 글
[ASP.NET] 한 큐에 정리하기 (0) | 2020.12.23 |
---|---|
[ASP.NET] API 요청 : CookieContainer, HttpWebRequest, HttpWebResponse (0) | 2020.12.22 |
ASP.NET 기초 클래스 (0) | 2020.12.18 |
ASP.NET 기본 소스 구조 (0) | 2020.12.17 |
ASP.NET 기본 상식 (0) | 2020.12.17 |
최근댓글