MCPcopy Create free account
hub / github.com/SincereCSL/Playgrounds / constructor

Method constructor

TypeScript/StudyTypeScript/src/class_01.ts:45–47  ·  view source on GitHub ↗
(name: string)

Source from the content-addressed store, hash-verified

43// private 只能类本身调用,不能被类的实例调用,也不能被类的子类调用
44class Dog3 {
45 constructor(name: string) {
46 this.name = name
47 }
48 public name: string
49 run() {}
50 private pri(){}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected