GitHub 博客园 Nanakon
上一页 1 ··· 4 5 6 7 8 9 10 11 12 ··· 110 下一页

2017年3月29日

摘要: import abc class BasePizza(object): __metaclass__ = abc.ABCMeta @abc.abstractmethod def get_ingredients(self): """Returns the ingredient list.""" class Calzone(BasePizza): d... 阅读全文
posted @ 2017-03-29 13:09 jzm17173 阅读(168) 评论(0) 推荐(0) 编辑

2017年3月28日

摘要: class Pizza(object): def __init__(self, size): self.size = size def get_size(self): return self.size #Pizza.get_size # #Pizza.get_size() # TypeError: get_size() missing 1 ... 阅读全文
posted @ 2017-03-28 13:24 jzm17173 阅读(91) 评论(0) 推荐(0) 编辑

2017年3月27日

摘要: import functools class SnareDrum(object): pass class Cymbal(object): pass class Stick(object): pass class Brushes(object): pass @functools.singledispatch def play(instrument, accessory): raise ... 阅读全文
posted @ 2017-03-27 08:48 jzm17173 阅读(60) 评论(0) 推荐(0) 编辑

2017年3月22日

摘要: Python之虚拟环境管理 阅读全文
posted @ 2017-03-22 09:16 jzm17173 阅读(66) 评论(0) 推荐(0) 编辑

2017年3月17日

摘要: 参数 scope The parent scope instance to be used for the modal's content. Defaults to $rootScope 阅读全文
posted @ 2017-03-17 16:13 jzm17173 阅读(72) 评论(0) 推荐(0) 编辑

2017年3月16日

摘要: memoization 是指通过缓存函数返回结果来加速函数调用的一种技术。仅当函数是纯函数 时结果才可以被缓存,也就是说,函数不能有任何副作用或输出,也不能依赖任何全局状态 LRU functools 模块提供了一个LRU(Least-Recently-Used)缓存装饰器。限定了缓存的条目数,当缓 阅读全文
posted @ 2017-03-16 09:17 jzm17173 阅读(160) 评论(0) 推荐(0) 编辑

2017年3月15日

摘要: (function() { angular.module('app.widgets') .directive('bsModalPlus', function($window, $sce, $modal) { return { restrict: 'A', scope: true,... 阅读全文
posted @ 2017-03-15 10:51 jzm17173 阅读(94) 评论(0) 推荐(0) 编辑
摘要: UI-Router:为什么开发者都不喜欢Angular.js内置的路由 学习 ui-router 系列文章索引 阅读全文
posted @ 2017-03-15 10:14 jzm17173 阅读(108) 评论(0) 推荐(0) 编辑
摘要: Using partialLoader 12_asynchronous-loading $translatePartialLoaderProvider 阅读全文
posted @ 2017-03-15 09:50 jzm17173 阅读(191) 评论(0) 推荐(0) 编辑

2017年3月14日

摘要: (function() { 'use strict'; angular.module('app.widgets') .directive('confirm', ['confirm2', 'toastr', function(confirm, toastr) { return { restrict: "... 阅读全文
posted @ 2017-03-14 19:45 jzm17173 阅读(127) 评论(0) 推荐(0) 编辑
上一页 1 ··· 4 5 6 7 8 9 10 11 12 ··· 110 下一页

导航

轻音