jOOPL JavaScript 面向对象框架

程序名称:jOOPL

授权协议: Apache

操作系统: 跨平台

开发语言: JavaScript

jOOPL 介绍

jOOPL 是一个 JavaScript 面向对象框架,全称是:”JavaScript Object-Oriented Programming
Library”.

一个轻量级、易用的面向对象编程库,允许使用纯 JavaScript 实现高级面向对象特性,包括

  • 继承.
  • 多态
  • 封装
  • 组合

示例代码

// First of all, we are going to declare a namespace for the class
$namespace.register("Joopl.Samples");

// Next part will be about designing the whole class
Joopl.Samples.polygon = $class.declare(
// The constructor
function() {
    // This is very recommended: if you declare a class field in the constructor,
    // it will hold a default value instead of undefined
    this.$_.args = null;
},
{
  // Sets an object that will hold the arguments to calculate the polygon's area
  set_Args: function(value) {
    this.$_.args = value;
  },

  // Gets an object that will hold the arguments to calculate the polygon's area
  get_Args: function() {
    return this.$_.args;
  },

  // The method to calculate the area. Check that its body does implement nothing.
  // Derived classes will be the ones responsible of providing the formula to make the calculation.
  CalculateArea: function() {
  }
}
);

jOOPL 官网

http://joopl.codeplex.com/

相关编程语言

MuPlayer 是一款跨平台、轻量级的音频播放解决方案,...
OS FLV 是一个 开源和可嵌入网页的flv播放器。 这个...
DewPlayer音乐播放器,样式很简单,而且很实用.播放器...
JW FLV MEDIA PLAYER是一个开源的在网页上使用的Fla...
Speakker 是一个基于 Web 浏览器的音乐播放器,只提...
Player Framework 是一个开源的支持 HTML5 的视频播...