---
title: "Discussion on \"Javascript实体对象生成器\" | Hashnode"
description: "Discussion on \"Javascript实体对象生成器\". 弄了一上午 模拟以前C#写了一个Javascript的对象生成器，支持对象转JSON集合，还有单属性访问器。没事技术含量为了熟悉原型以及原型链做的练习。\n//申明扩展类\nvar ExtendClass = function () { };\n\n//属性访问器\nExtendClass.prototype.accessor = function () {\n    this.get = function () {\n        return this.val;\n    }\n    this.set =..."
url: "https://hashnode.com/posts/javascript-shi-ti-dui-xiang-sheng-cheng-qi/628d95e9b4bd016fc9a32a79"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Javascript实体对象生成器](https://www.topzs.com/javascript-shi-ti-dui-xiang-sheng-cheng-qi?utm_source=hashnode&utm_medium=feed)

弄了一上午 模拟以前C#写了一个Javascript的对象生成器，支持对象转JSON集合，还有单属性访问器。没事技术含量为了熟悉原型以及原型链做的练习。 //申明扩展类 var ExtendClass = function () { }; //属性访问器 ExtendClass.prototype.accessor = function () { this.get = function () { return this.val; } this.set =...

Mar 12, 2014 · 2 min read · topzs.com  
Read the article

## Written by

[Topaz](https://hashnode.com/@tangchang)

@tangchang

  
[View profile](https://hashnode.com/@tangchang)

Front-end development

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
