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판)
563
14
장
상속: 득과 실
super(
)
의 두 인수 모두 이제는 선택적이다. 파이썬
3
바이트코드 컴파일러는 메서드 안에서
super
()
가 호출될 때 주변 환경을 돌아보고 인수를 자동으로 제공한다. 두 인수는 다음과 같다.
type
원하는 메서드를 구현하는 슈퍼클래스 검색 경로의 시작. 기본값으로 이는
super(
)
를 호
출한 메서드를 소유한 클래스가 된다.
obje
ct_or_ty
pe
인스턴스 메서드 호출 시에는 인스턴스, 클래스 메서드 호출 시에는 클래스가 이 메서드 호
출의 수신자가 된다. 기본적으로 인스턴스 메서드 안에서
super
(
)
를 호출하면 수신자는 객
체 자신인
self
가 된다.
여러분이든 컴파일러든 이 인수들을 제공하면,
super(
)
함수는
type
매개변수의 슈퍼클래스
안에 있는 메서드
(
이 예에서는
__setitem__(
)
)
를 찾아내는 동적 프록시 객체
dynamic
proxy
object
를 반환하고 이 객체를
object_or_type
에 할당하므로, 메서드를 호출할 때 수신자
(
self
)
를
전달할 필요가 없다.
파이썬
3
에서도
super(
)
를 호출할 때 첫 번째와 두 번째 인수를 명시적으로 전달할 수 있다.
3
그러나 테스트나 디버깅을 하려고 메서드 결정 순서
(
MRO
)
일부분을 건너뛰거나, 슈퍼클래스
의 바람직하지 않은 처리를 ...
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