代码搜索:self
找到约 10,000 项符合「self」的源代码
代码结果 10,000
www.eeworm.com/read/465716/7052457
py state.py
#: c04:statemachine:State.py
# A State has an operation, and can be moved
# into the next State given an Input:
class State:
def run(self):
assert 1, "run not implemented"
def next(se
www.eeworm.com/read/465716/7052461
py templatemethod.py
#: c03:TemplateMethod.py
# Simple demonstration of Template Method.
class ApplicationFramework:
def __init__(self):
self.__templateMethod()
def __templateMethod(self):
for i in ran
www.eeworm.com/read/465716/7052477
py singletonpattern.py
#: c01:SingletonPattern.py
class OnlyOne:
class __OnlyOne:
def __init__(self, arg):
self.val = arg
def __str__(self):
return `self` + self.val
instance = None
def _
www.eeworm.com/read/465716/7052499
py flowervisitors.py
#: c11:FlowerVisitors.py
# Demonstration of "visitor" pattern.
from __future__ import generators
import random
# The Flower hierarchy cannot be changed:
class Flower(object):
def accept(se
www.eeworm.com/read/465716/7052508
py boxobserver.py
#: c10:BoxObserver.py
""" Written by Kevin Altis as a first-cut for
converting BoxObserver to Python. The Observer
hasn't been integrated yet.
To run this program, you must:
Install WxPython from
www.eeworm.com/read/374725/7074904
a02380 short6713.cdb.a02380
//! c6713 Base Seed
//# c6x1x.cdb 4.82.150
object IRAM :: MEM {
param iComment :: "This object defines space for the DSP's on-chip memory"
param iIsUsed :: 1
param iId :: 0
param iDe
www.eeworm.com/read/364251/7076017
py generator.py
#!/usr/bin/python -u
#
# generate python wrappers from the XML API description
#
functions = {}
enums = {} # { enumType: { enumConstant: enumValue } }
import os
import sys
import string
if __name__
www.eeworm.com/read/364251/7076022
py libxml.py
import libxml2mod
import types
import sys
# The root of all libxml2 errors.
class libxmlError(Exception): pass
#
# id() is sometimes negative ...
#
def pos_id(o):
i = id(o)
if (i < 0):
www.eeworm.com/read/201012/7087463
cdb demo5402.cdb
//!
//# sd54.cdb 4.80.208
object USERREGS :: MEM {
param iComment :: "This object defines space for the DSP's memory mapped registers and can't be deleted"
param iIsUsed :: 1
param iId :
www.eeworm.com/read/387381/7116195
cpp btcommtransport.cpp
// Copyright (c) 2004 - 2007, Symbian Software Ltd. All rights reserved.
#include "btcommtransport.h"
CBtCommTransport* CBtCommTransport::NewL(TAny* aTransportCreateInfo)
/**
Factory functi