Skip to Content
For Enterprise
For Government
For Higher Ed
For Individuals
For Marketing
For Enterprise
For Government
For Higher Ed
For Individuals
For Marketing
Explore Skills
Cloud Computing
Microsoft Azure
Amazon Web Services (AWS)
Google Cloud
Cloud Migration
Cloud Deployment
Cloud Platforms
Data Engineering
Data Warehouse
SQL
Apache Spark
Microsoft SQL Server
MySQL
Kafka
Data Lake
Streaming & Messaging
NoSQL Databases
Relational Databases
Data Science
Pandas
R
MATLAB
SAS
D3
Power BI
Tableau
Statistics
Exploratory Data Analysis
Data Visualization
AI & ML
Generative AI
Machine Learning
Artificial Intelligence (AI)
Deep Learning
Reinforcement Learning
Natural Language Processing
TensorFlow
Scikit-Learn
Hyperparameter Tuning
MLOps
Programming Languages
Java
JavaScript
Spring
Python
Go
C#
C++
C
Swift
Rust
Functional Programming
Software Architecture
Object-Oriented
Distributed Systems
Domain-Driven Design
Architectural Patterns
IT/Ops
Kubernetes
Docker
GitHub
Terraform
Continuous Delivery
Continuous Integration
Database Administration
Computer Networking
Operating Systems
IT Certifications
Security
Network Security
Application Security
Incident Response
Zero Trust Model
Disaster Recovery
Penetration Testing / Ethical Hacking
Governance
Malware
Security Architecture
Security Engineering
Security Certifications
Design
Web Design
Graphic Design
Interaction Design
Film & Video
User Experience (UX)
Design Process
Design Tools
Business
Agile
Project Management
Product Management
Marketing
Human Resources
Finance
Team Management
Business Strategy
Digital Transformation
Organizational Leadership
Soft Skills
Professional Communication
Emotional Intelligence
Presentation Skills
Innovation
Critical Thinking
Public Speaking
Collaboration
Personal Productivity
Confidence / Motivation
Features
All features
Verifiable skills
AI Academy
Courses
Certifications
Interactive learning
Live events
Superstreams
Answers
Insights reporting
Radar Blog
Buy Courses
Plans
Sign In
Try Now
O'Reilly Platform
book
전문가를 위한 파이썬(2판)
by
루시아누 하말류
,
강권학
November 2024
Beginner to intermediate
1064 pages
25h 21m
Korean
Hanbit Media, Inc.
Content preview from
전문가를 위한 파이썬(2판)
239
5
장
데이터 클래스 빌더
default_factory
는
field
(
)
함수에서 가장 널리 사용되는 옵션이지만,
field
(
)
함수는
[표
5
-
3
]의 다른 옵션들도 사용할 수 있다.
표
5-3
field
()
함수에 사용할 수 있는 키워드 인수들
옵션
의미
기본값
default
필드의 기본값
_
MISSING
_
TYPE
*
default
_
factory
기본값을 생성하는 무인수 함수
_
MISSING
_
TYPE
init
필드를
__
init
__()
매개변수에 포함시킨다.
True
repr
필드를
__
repr
__()
이 출력하게 한다.
True
compare
필드를
__
eq
__()
,
__
lt
__()
등의 비교 메서드에서 사용하게 한다.
True
hash
필드를
__
hash
__()
계산에 포함시킨다.
None
**
metadata
사용자 정의 데이터의 매핑.
@
dataclass
가 무시한다.
None
*
dataclass
._
MISSING
_
TYPE
은 구분 표싯값인 센티넬값
sentinel
value
으로서 옵션이 제공되지 않았음을 나타낸다.
None
이 실제 기본값으로 널리 쓰이므로, 옵션을 설정하지 않은 경우와 구분하는 데 사용한다.
**
compare
=
True
로 설정되었을 때만
hash
=
None
인 필드가
__
hash
__()
계산에 사용된다.
필드 어노테이션에서 기본값 자리를
field(
)
함수가 차지하므로 ...
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.
Start your free trial
You might also like
전문가를 위한 리액트
테자스 쿠마르
데이터로 전문가처럼 말하기
칼 올친
개발자를 위한 머신러닝&딥러닝
로런스 모로니
고성능 파이썬(2판)
오현석, 미샤 고렐릭, 이안 오스발트
Publisher Resources
ISBN: 9791169211772