Skip to Content
우아한 C언어 코딩 패턴
book

우아한 C언어 코딩 패턴

by Christoper Preschem, 정기훈(Jung Ki Hun)
April 2024
Beginner to intermediate
364 pages
7h 2m
Korean
Insight
Content preview from 우아한 C언어 코딩 패턴
Fluent
200
󻱴󽴔󽴔󻯯󻪿󼨫󽴔
UsbIOCTL.h 중 하나를 포함해야 한다.
그림 6.2는 장치 드라이버 API의 최종 버전 소스 코드 파일에 대한 include
관계를 보여준다. 이때, EthApplication.c 코드는 USB 관련 헤더 파일에 의
존하지 않는다. 예를 들어, 새로운 USB-IOCTL이 추가되어도 코드에 표시된
EthApplication.c는 종속 파일이 변경되지 않기 때문에 다시 컴파일할 필요조
차 없다.
이번 장에서 제시된 모든 코드 조각 중에서 가장 마지막 버전이 장치 드라이버
의 가장 유연한 코드 조각이지만 여러분이 원하는 것이 아닐 수도 있음을 명심
해야 한다. 인터페이스가 복잡할수록 유연성은 커진다. 코드를 필요한 만큼 유
연하게 만드는 동시에 최대한 단순하게 유지하려 노력해야 한다.
󻭣󻩌
이번 장에서는 C에 대한 네 가지 API 패턴에 대해 설명하고, 장치 드라이버를
설계하는 방법의 실행 예제를 통해 패턴의 적용 사례를 살펴보았다. 헤더 파일
패턴은 .h 파일에 잘 정의된 인터페이스를 제공하면서 .c 파일에 세부 구현을
숨겨야 한다는 기본 개념을 알려준다. 핸들 패턴은 상태 정보를 공유하기 위해
함수 간에 불투명한 데이터 타입을 전달하는 잘 알려진 개념에 관한 내용이다.
동적 인터페이스 패턴은 콜백 함수를 통해 호출자별로 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

AI를 위한 필수 수학

AI를 위한 필수 수학

할라 넬슨
파이썬으로 살펴보는 아키텍처 패턴

파이썬으로 살펴보는 아키텍처 패턴

오현석, 해리 퍼시벌, 밥 그레고리
개발 7년차, 매니저 1일차

개발 7년차, 매니저 1일차

권원상, 한민주, 카미유 푸르니에
클라우드 네이티브 애플리케이션 디자인 패턴

클라우드 네이티브 애플리케이션 디자인 패턴

카순 인드라시리, 스리스칸다라자 수호티얀

Publisher Resources

ISBN: 9788966264742