code stringlengths 4 4.48k | docstring stringlengths 1 6.45k | _id stringlengths 24 24 |
|---|---|---|
class RainBirdSensor(SensorEntity): <NEW_LINE> <INDENT> def __init__(self, controller: RainbirdController, sensor_type): <NEW_LINE> <INDENT> self._sensor_type = sensor_type <NEW_LINE> self._controller = controller <NEW_LINE> self._name = SENSOR_TYPES[self._sensor_type][0] <NEW_LINE> self._icon = SENSOR_TYPES[self._sens... | A sensor implementation for Rain Bird device. | 62598f0a7cff6e4e811b4518 |
class UploadCommand(Command): <NEW_LINE> <INDENT> description = "Build and publish the package." <NEW_LINE> user_options = [] <NEW_LINE> @staticmethod <NEW_LINE> def status(s): <NEW_LINE> <INDENT> print("\033[1m{0}\033[0m".format(s)) <NEW_LINE> <DEDENT> def initialize_options(self): <NEW_LINE> <INDENT> pass <NEW_LINE> ... | Support setup.py upload. | 62598f0a3d592f4c4edb9a19 |
class AddArticleForm(ModelForm): <NEW_LINE> <INDENT> class Meta: <NEW_LINE> <INDENT> model = Article <NEW_LINE> fields = ['article_name','article_post','owner'] <NEW_LINE> widgets={ "article_name": forms.Textarea(attrs={'cols': 80, 'rows': 1}), "article_post": forms.Textarea(attrs={'cols': 80, 'rows': 10}), } <NEW_LINE... | docstring for ClassName | 62598f0a3617ad0b5ee04c5d |
class MagicNumber(FileElement): <NEW_LINE> <INDENT> len_formats = {4: ">L", 8: ">Q"} <NEW_LINE> def __init__(self, num_bytes, offset=None): <NEW_LINE> <INDENT> FileElement.__init__(self, '{}-bit magic number'.format(num_bytes * 8)) <NEW_LINE> self._num_bytes = num_bytes <NEW_LINE> self._offset = offset <NEW_LINE> <DEDE... | A :class:`FileElement` that returns a byte sequence in the file. | 62598f0a167d2b6e312b5acc |
class Test(unittest.TestCase): <NEW_LINE> <INDENT> def testSomething(self): <NEW_LINE> <INDENT> pass | Basic tests for the system sub-package. | 62598f0a71ff763f4b5e6295 |
class TestDiveCCAir(TestDiveCCAirBase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> super().setUp() <NEW_LINE> settings.RUN_TIME = False <NEW_LINE> self.setpoint = 1.2 <NEW_LINE> self.dive_tank = self.ccair <NEW_LINE> self.all_tanks = [self.ccair] <NEW_LINE> self.do_dive() | Class for test air dive. | 62598f0ad8ef3951e32c73ec |
class Affinity(object): <NEW_LINE> <INDENT> __slots__ = ( 'name', 'limits', 'constraints', ) <NEW_LINE> def __init__(self, name, limits=None): <NEW_LINE> <INDENT> self.name = name <NEW_LINE> self.limits = collections.defaultdict(lambda: float('inf')) <NEW_LINE> if limits: <NEW_LINE> <INDENT> self.limits.update(limits) ... | Model affinity and affinity limits.
| 62598f0af548e778e596a0ba |
class HasDtype(LabelSelector): <NEW_LINE> <INDENT> def __init__( self, include: Optional[Dtypes] = None, exclude: Optional[Dtypes] = None, ) -> None: <NEW_LINE> <INDENT> super().__init__(axis="columns", level=None) <NEW_LINE> self.include = include and iterutils.to_set(include) <NEW_LINE> self.exclude = exclude and ite... | Select columns based on the column dtypes.
Parameters
----------
include, exclude: scalar or list-like
A selection of dtypes or strings to be included/excluded. At least one of
these parameters must be supplied.
Raises
------
ValueError
If both of ``include`` and ``exclude`` are empty;
if ``include`` ... | 62598f0a851cf427c66b6dfb |
class AddSmailTests( CommonDecoratorsTests, OwnedNotClosedInforequestArgTests, CanAddActionTests, DraftBranchFieldTests, DraftEffectiveDateFieldTests, DraftSubjectContentAttachmentsFieldsTests, AddSmailAndNewActionCommonTests, ): <NEW_LINE> <INDENT> u <NEW_LINE> view_name = None <NEW_LINE> good_scenario = None <NEW_LIN... | Absract tests for ``add_smail_*()`` views registered as "inforequests:add_smail_*". | 62598f0a5fc7496912d4780c |
class RemoveEditLockResponse: <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self.swaggerTypes = { 'result': 'RemoveEditLockResult', 'status': 'str', 'error_message': 'str' } <NEW_LINE> self.result = None <NEW_LINE> self.status = None <NEW_LINE> self.error_message = None | NOTE: This class is auto generated by the swagger code generator program.
Do not edit the class manually. | 62598f0a60cbc95b06362e64 |
class Session(models.Model): <NEW_LINE> <INDENT> year = models.CharField(max_length=4) <NEW_LINE> term = models.ForeignKey(Term, on_delete=models.DO_NOTHING) <NEW_LINE> title = models.CharField(max_length=256) <NEW_LINE> description = models.TextField(null=True, blank=True) <NEW_LINE> note = models.TextField(null=True,... | Create a Session model | 62598f0a656771135c4881be |
class CiscoDeviceManagementApi(object): <NEW_LINE> <INDENT> def __init__(self, topic, host): <NEW_LINE> <INDENT> self.host = host <NEW_LINE> target = oslo_messaging.Target(topic=topic, version='1.0') <NEW_LINE> self.client = n_rpc.get_client(target) <NEW_LINE> <DEDENT> def report_dead_hosting_devices(self, context, hd_... | Agent side of the device manager RPC API. | 62598f0bff9c53063f519192 |
class GAppLauncContext( gobject__GObject.GObject): <NEW_LINE> <INDENT> def __init__( self, obj = None): <NEW_LINE> <INDENT> if obj: self._object = obj <NEW_LINE> else: <NEW_LINE> <INDENT> libgio.g_app_launch_context_new.restype = POINTER(c_int) <NEW_LINE> libgio.g_app_launch_context_new.argtypes = [] <NEW_LINE> self._... | Class GAppLauncContext Constructors | 62598f0b3346ee7daa336bfd |
class OrderProblemSchema(SchemaObject): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self.schema = 'OrderProblem' | Schema Mixin for OrderProblem
Usage: place after django model in class definition, schema will return the schema.org url for the object
OrderStatus representing that there is a problem with the order. | 62598f0b5fcc89381b2656c6 |
class Report(Table): <NEW_LINE> <INDENT> __slots__ = () <NEW_LINE> SERIALIZE_CSV = 'csv' <NEW_LINE> SERIALIZE_TTY = 'tty' <NEW_LINE> def serialize(self, mode, writer, column_names=True): <NEW_LINE> <INDENT> if self.is_empty(): <NEW_LINE> <INDENT> return self <NEW_LINE> <DEDENT> cols = self.columns <NEW_LINE> colnames =... | A report is essentially a table, with the ability to serialize itself to common formats.
@note reports keep their values plain, but assume their conversion by the schema's constructor before
serialization. | 62598f0b091ae3566870374e |
class ReplayMemory(object): <NEW_LINE> <INDENT> def __init__(self, memory_size, shape): <NEW_LINE> <INDENT> self._memory_size = memory_size <NEW_LINE> self._value_number = len(shape) <NEW_LINE> self._memory_pool = [] <NEW_LINE> self._shape = [] <NEW_LINE> for i in range(self._value_number): <NEW_LINE> <INDENT> self._sh... | Replay memories to store training sample with a time window | 62598f0b55399d3f0562505a |
class _Hook(): <NEW_LINE> <INDENT> def __init__(self, function, _type): <NEW_LINE> <INDENT> self.function = function <NEW_LINE> self.type = _type <NEW_LINE> self.kwargs = {} <NEW_LINE> <DEDENT> def _add_hook(self, kwargs): <NEW_LINE> <INDENT> self.kwargs.update(kwargs) | :type function: function
:type type: str
:type kwargs: dict[str, unknown] | 62598f0b4a966d76dd5eda08 |
class GfycatImageExtractor(GfycatExtractor): <NEW_LINE> <INDENT> subcategory = "image" <NEW_LINE> filename_fmt = "{category}_{gfyName}.{extension}" <NEW_LINE> pattern = [r"(?:https?://)?(?:[a-z]+\.)?gfycat\.com/" r"(?:(?:gifs/)?detail/|ifr/)?([A-Za-z]+)"] <NEW_LINE> test = [ ("https://gfycat.com/GrayGenerousCowrie", { ... | Extractor for individual images from gfycat.com | 62598f0b283ffb24f3cf23e1 |
class ForwardZoneMixin(ValidationMixin): <NEW_LINE> <INDENT> def validate(self, data): <NEW_LINE> <INDENT> data = super().validate(data) <NEW_LINE> if data.get('name'): <NEW_LINE> <INDENT> data['zone'] = ForwardZone.get_zone_by_hostname(data['name']) <NEW_LINE> <DEDENT> return data | Create a zone entry from the hostname. | 62598f0bf9cc0f698b1c4869 |
class OpenStackServiceCatalog(object): <NEW_LINE> <INDENT> _auth_version = None <NEW_LINE> _service_catalog = None <NEW_LINE> def __init__(self, service_catalog, ex_force_auth_version=None): <NEW_LINE> <INDENT> self._auth_version = ex_force_auth_version or AUTH_API_VERSION <NEW_LINE> self._service_catalog = {} <NEW_LIN... | http://docs.openstack.org/api/openstack-identity-service/2.0/content/
This class should be instanciated with the contents of the
'serviceCatalog' in the auth response. This will do the work of figuring
out which services actually exist in the catalog as well as split them up
by type, name, and region if available | 62598f0b7c178a314d78bfd4 |
class TimeSeries(Model): <NEW_LINE> <INDENT> EOOBJ_CLASS = DatasetSeries <NEW_LINE> eoobj = OneToOneField( EOOBJ_CLASS, on_delete=PROTECT, related_name='damats_time_series', verbose_name='Related Dataset Series' ) <NEW_LINE> name = CharField(max_length=256, null=True, blank=True) <NEW_LINE> description = TextField(null... | DAMATS Image Time Series (aka SITS)
| 62598f0b50812a4eaa620186 |
class ReversionRegistrationTest(TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> reversion.register(TestModel) <NEW_LINE> <DEDENT> def testCanRegisterModel(self): <NEW_LINE> <INDENT> self.assertTrue(reversion.is_registered(TestModel)) <NEW_LINE> self.assertRaises(RegistrationError, lambda: reversion.... | Tests the django-reversion registration functionality. | 62598f0b167d2b6e312b5ad0 |
class EnsembleModelWithAlignment(EnsembleModel): <NEW_LINE> <INDENT> def __init__(self, models): <NEW_LINE> <INDENT> super().__init__(models) <NEW_LINE> <DEDENT> def forward_align(self, src_tokens, src_lengths, prev_output_tokens): <NEW_LINE> <INDENT> avg_attn = None <NEW_LINE> for model in self.models: <NEW_LINE> <IND... | A wrapper around an ensemble of models. | 62598f0b3346ee7daa336bfe |
class ProductDetails(object): <NEW_LINE> <INDENT> json_data = {} <NEW_LINE> def __init__(self): <NEW_LINE> <INDENT> json_dir = settings_fallback('PROD_DETAILS_DIR') <NEW_LINE> for filename in os.listdir(json_dir): <NEW_LINE> <INDENT> if filename.endswith('.json'): <NEW_LINE> <INDENT> name = os.path.splitext(filename)[0... | Main product details class. Implements the JSON files' content as
attributes, e.g.: product_details.firefox_version_history . | 62598f0b5fcc89381b2656c7 |
class ClassList(models.Model): <NEW_LINE> <INDENT> title = models.CharField(verbose_name='班级',max_length=32) | 班级表 | 62598f0b97e22403b3839a17 |
@attr.s(init=False) <NEW_LINE> class Func(object): <NEW_LINE> <INDENT> func = attr.ib() <NEW_LINE> args = attr.ib() <NEW_LINE> kwargs = attr.ib() <NEW_LINE> def __init__(self, func, *args, **kwargs): <NEW_LINE> <INDENT> self.func = func <NEW_LINE> self.args = args <NEW_LINE> self.kwargs = kwargs | An intent that returns the result of the specified function.
Note that Func is something of a cop-out. It doesn't follow the
convention of an intent being transparent data that is easy to introspect,
since it just wraps an opaque callable. This has two drawbacks:
- it's harder to test, since the only thing you can do... | 62598f0b099cdd3c63674972 |
class TestDebitMemoObjectNSFields(unittest.TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def tearDown(self): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def testDebitMemoObjectNSFields(self): <NEW_LINE> <INDENT> pass | DebitMemoObjectNSFields unit test stubs | 62598f0b091ae35668703750 |
class User: <NEW_LINE> <INDENT> def __init__(self, _id, _gender, _age, _preference): <NEW_LINE> <INDENT> self.id = _id <NEW_LINE> self.gender = _gender <NEW_LINE> self.age = _age <NEW_LINE> self.preference = _preference <NEW_LINE> self.click_record = set() <NEW_LINE> self.dislike_set = set() | User class
Attributes:
id: string
gender: int, 1 for men and 0 for women
age: int
preference: array
click_record: set, the items clicked, denoted by iid
dislike_set: set, the disliked items, denoted by iid | 62598f0bf548e778e596a0be |
class PlayerView(record('player')): <NEW_LINE> <INDENT> def paint(self): <NEW_LINE> <INDENT> glPushMatrix() <NEW_LINE> position = self.player.getPosition() <NEW_LINE> glTranslate(position.x, position.y, position.z) <NEW_LINE> glRotate(self.player.orientation.y, 0.0, 1.0, 0.0) <NEW_LINE> glTranslate(-0.5, 0, -0.5) <NEW_... | View of a player. | 62598f0b60cbc95b06362e68 |
class TrainningDataView(generics.ListCreateAPIView): <NEW_LINE> <INDENT> queryset = TrainingBlockModel.objects.all() <NEW_LINE> serializer_class = TrainingBlockSerializer <NEW_LINE> def perform_create(self, serializer): <NEW_LINE> <INDENT> serializer.save() <NEW_LINE> columns_title = [ "epoch", "empty_num", "block_coun... | TrainningView | 62598f0b5fdd1c0f98e5cad7 |
class _TemporaryReceivingDetails: <NEW_LINE> <INDENT> total_discounts = currency(0) <NEW_LINE> total_surcharges = currency(0) <NEW_LINE> receiving_subtotal = currency(0) <NEW_LINE> receiving_total = currency(0) <NEW_LINE> received_freight = currency(0) <NEW_LINE> received_freight_type = u'' <NEW_LINE> def __init__(self... | A workaround class, used to summarize a list of receiving order | 62598f0b26068e7796d4b48e |
class ConfigEmailLookup(buildbot.util.ComparableMixin): <NEW_LINE> <INDENT> zope.interface.implements(buildbot.interfaces.IEmailLookup) <NEW_LINE> compare_attrs = ["author_filename", "default_address", "only_addresses"] <NEW_LINE> def __init__(self, author_filename, default_address, only_addresses = None, update_interv... | Email lookup implementation which searchs a user specified configuration
file to match commit authors to email addresses. | 62598f0bfbf16365ca792bd4 |
class SubBreed(models.Model): <NEW_LINE> <INDENT> name = models.CharField(max_length=30) <NEW_LINE> breed = models.ForeignKey( to=Breed, on_delete=models.SET_NULL, null=True, blank=True ) <NEW_LINE> class Meta: <NEW_LINE> <INDENT> verbose_name = "Sub-Breed" <NEW_LINE> verbose_name_plural = "Sub-Breeds" <NEW_LINE> <DEDE... | Representation of a dog's sub-breed. | 62598f0b167d2b6e312b5ad2 |
class TestOWLNamedObjectVisitorEx(TestCase): <NEW_LINE> <INDENT> pass | OWLNamedObjectVisitorEx test cases | 62598f0b3346ee7daa336bff |
class PicCodeHandler(BaseHandler): <NEW_LINE> <INDENT> def get(self): <NEW_LINE> <INDENT> pre_code_id = self.get_argument("pre","") <NEW_LINE> cur_code_id = self.get_argument("cur") <NEW_LINE> name,text,pic = captcha.generate_captcha() <NEW_LINE> if pre_code_id: <NEW_LINE> <INDENT> try: <NEW_LINE> <INDENT> self.redis.d... | 图片验证码 | 62598f0b5fcc89381b2656c8 |
class GH_UngroupGeometryComponent(GH_Component,IGH_InstanceDescription,GH_ISerializable,IGH_DocumentObject,IGH_ActiveObject,IGH_Component,IGH_PreviewObject,IGH_BakeAwareObject): <NEW_LINE> <INDENT> def AfterSolveInstance(self,*args): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def AppendAdditionalComponentMenuItems(se... | GH_UngroupGeometryComponent() | 62598f0bcc40096d61619776 |
class inertia: <NEW_LINE> <INDENT> __metaclass__ = ABCMeta <NEW_LINE> def __init__(self, density, isotropic=False): <NEW_LINE> <INDENT> self.density = density <NEW_LINE> self.isotropic = isotropic <NEW_LINE> <DEDENT> @abstractmethod <NEW_LINE> def _mass(self): <NEW_LINE> <INDENT> raise NotImplementedError('mass has not... | Abstract base class for drag coeffecients | 62598f0b5fc7496912d4780f |
class LazyMixinExample(LazyMixin): <NEW_LINE> <INDENT> __slots__ = 'example' <NEW_LINE> prefix = "Hello World" <NEW_LINE> def _set_cache_(self, attr): <NEW_LINE> <INDENT> if attr == 'example': <NEW_LINE> <INDENT> self.example = "%s - this is cached" % self.prefix <NEW_LINE> <DEDENT> else: <NEW_LINE> <INDENT> return sup... | Example for LazyMixin | 62598f0b283ffb24f3cf23e5 |
class ReleaseDelete(OIDCLoginRequiredMixin, PermissionRequiredMixin, DeleteView): <NEW_LINE> <INDENT> model = Tool <NEW_LINE> permission_required = 'api.destroy_tool_release' <NEW_LINE> def get_success_url(self): <NEW_LINE> <INDENT> messages.success(self.request, "Successfully deleted release") <NEW_LINE> return revers... | Deletes a release for a tool from the control panel application. | 62598f0bab23a570cc2d4308 |
@implementer(IPortalCatalogQueueProcessor) <NEW_LINE> class PortalCatalogProcessor(object): <NEW_LINE> <INDENT> def index(self, obj, attributes=None): <NEW_LINE> <INDENT> catalog = getToolByName(obj, 'portal_catalog', None) <NEW_LINE> if catalog is not None: <NEW_LINE> <INDENT> catalog._indexObject(obj) <NEW_LINE> <DED... | An index queue processor for the standard portal catalog via
the `CatalogMultiplex` and `CMFCatalogAware` mixin classes | 62598f0b9f28863672817330 |
@implementer(IObjectReplaced) <NEW_LINE> class ObjectReplaced(object): <NEW_LINE> <INDENT> def __init__(self, old_object, new_object): <NEW_LINE> <INDENT> self.old_object = old_object <NEW_LINE> self.new_object = new_object | An event sent when an object has been replaced. | 62598f0bfbf16365ca792bd6 |
class ErrorLogger(object): <NEW_LINE> <INDENT> def debug(self, msg): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def warning(self, msg): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def error(self, msg): <NEW_LINE> <INDENT> print(msg) | Error ONLY logger for YouTubeDL | 62598f0b5fcc89381b2656c9 |
class CampbellBozorgnia2014HighQJapanSite(CampbellBozorgnia2014HighQ): <NEW_LINE> <INDENT> CONSTS = JAPAN_CONSTS | Implements the Campbell & Bozorgnia (2014) NGA-West2 GMPE, for the low
attenuation (high quality factor) coefficients, for the case in which
the "Japan" shallow site response term is activited | 62598f0b0fa83653e46f3a1e |
class RebuildDeleteObjects(RebuildTestBase): <NEW_LINE> <INDENT> def __init__(self, *args, **kwargs): <NEW_LINE> <INDENT> super(RebuildDeleteObjects, self).__init__(*args, **kwargs) <NEW_LINE> self.punched_indices = None <NEW_LINE> self.punched_qty = 0 <NEW_LINE> self.punch_type = None <NEW_LINE> <DEDENT> def execute_d... | Test class for deleting objects during pool rebuild.
Test Class Description:
This class contains tests for deleting objects from a container during
rebuild.
:avocado: recursive | 62598f0bdc8b845886d52101 |
class ComputeTargetHttpProxiesGetRequest(_messages.Message): <NEW_LINE> <INDENT> project = _messages.StringField(1, required=True) <NEW_LINE> targetHttpProxy = _messages.StringField(2, required=True) | A ComputeTargetHttpProxiesGetRequest object.
Fields:
project: Name of the project scoping this request.
targetHttpProxy: Name of the TargetHttpProxy resource to return. | 62598f0b31939e2706ed0fff |
class Datasets(MultiSettingWidget): <NEW_LINE> <INDENT> def __init__(self, setting, doc, dimensions, datatype, *args): <NEW_LINE> <INDENT> MultiSettingWidget.__init__(self, setting, doc, *args) <NEW_LINE> self.dimensions = dimensions <NEW_LINE> self.datatype = datatype <NEW_LINE> self.lastdatasets = [] <NEW_LINE> self.... | A control for editing a list of datasets. | 62598f0b4527f215b58e8a34 |
class Record: <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self.file_name = "" <NEW_LINE> self.comments = {} <NEW_LINE> for kw in CKEYWORDS: <NEW_LINE> <INDENT> self.comments[kw.lower()] = None <NEW_LINE> <DEDENT> self.sites = [] <NEW_LINE> self.seq = "" <NEW_LINE> self.seq_trimmed = "" | Hold information from a PHD file. | 62598f0bf9cc0f698b1c486c |
class Price_To_Earnings(CustomFactor): <NEW_LINE> <INDENT> inputs = [morningstar.valuation_ratios.pe_ratio] <NEW_LINE> window_length = 1 <NEW_LINE> def compute(self, today, assets, out, pe): <NEW_LINE> <INDENT> out[:] = pe[-1] | Price to Earnings Ratio:
Closing price divided by earnings per share.
https://www.pnc.com/content/dam/pnc-com/pdf/personal/wealth-investments/WhitePapers/FactorAnalysisFeb2014.pdf
Notes:
Low P/E Ratio suggests that an equity cheap
Differs substantially between sectors | 62598f0b656771135c4881c6 |
class WSGIServer(Server): <NEW_LINE> <INDENT> def __new__(cls, wsgifile, hostname="", port=None, handler_cls=WSGIRequestHandler, server_cls=WSGIHTTPServer, *args, **kwargs): <NEW_LINE> <INDENT> instance = super(WSGIServer, cls).__new__( cls, hostname=hostname, port=port, handler_cls=handler_cls, server_cls=server_cls, ... | Starts a wsgi server using a wsgifile, the wsgifile is a python file that
has an application property | 62598f0b26068e7796d4b492 |
class SemParser(BaseParser): <NEW_LINE> <INDENT> root = sem_phrase <NEW_LINE> def interpret(self, result, start, end): <NEW_LINE> <INDENT> m = 'sem' <NEW_LINE> c = Compound() <NEW_LINE> c.microscopy.append(m) <NEW_LINE> yield c | Parser for Scanning Electron Microscopy (SEM) instances
Usage::
tt = Sentence(input).tagged_tokens
SemParser.parse(tt)
.. note::
Usually called as part of a list of parsers in doc.text.py objects | 62598f0bfbf16365ca792bd8 |
class ObjectProxy(object): <NEW_LINE> <INDENT> def __init__(self, wrapped): <NEW_LINE> <INDENT> self.wrapped = wrapped <NEW_LINE> try: <NEW_LINE> <INDENT> self.__name__ = wrapped.__name__ <NEW_LINE> <DEDENT> except AttributeError: <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> <DEDENT> @property <NEW_LINE> def __class__(... | Proxy object. | 62598f0b3346ee7daa336c01 |
class Source(object): <NEW_LINE> <INDENT> @staticmethod <NEW_LINE> def get(context): <NEW_LINE> <INDENT> return context['job'].table <NEW_LINE> <DEDENT> @staticmethod <NEW_LINE> def message_context(context, result): <NEW_LINE> <INDENT> if 'job' in context: <NEW_LINE> <INDENT> d = context['job'].criteria <NEW_LINE> r = ... | Encapsulate access and encoding of source data objects.
This class acts as a bridging API from source data to the
Alerting module. | 62598f0b5fcc89381b2656ca |
class Normal(NoUncertainty): <NEW_LINE> <INDENT> distribution = sa.NormalUncertainty <NEW_LINE> @staticmethod <NEW_LINE> def repair(obj): <NEW_LINE> <INDENT> if obj['uncertainty']['variance with pedigree uncertainty'] == 0: <NEW_LINE> <INDENT> return remove_exchange_uncertainty(obj) <NEW_LINE> <DEDENT> obj['uncertainty... | `Normal distribution <https://en.wikipedia.org/wiki/Normal_distribution>`__, defined by mean and variance. | 62598f0b71ff763f4b5e629f |
class AdHoc(object): <NEW_LINE> <INDENT> JOB_TYPE = 'run' <NEW_LINE> JOB_EXPLANATION = 'Ad Hoc job run by tower-companion' <NEW_LINE> def __init__(self): <NEW_LINE> <INDENT> self.inventory_id = None <NEW_LINE> self.credential_id = None <NEW_LINE> self.module_name = None <NEW_LINE> self.module_args = None <NEW_LINE> sel... | AdHoc job | 62598f0b0fa83653e46f3a20 |
class Class(object): <NEW_LINE> <INDENT> IN = 1 <NEW_LINE> CS = 2 <NEW_LINE> CH = 3 <NEW_LINE> HS = 4 <NEW_LINE> ANY = 255 <NEW_LINE> by_string = { "IN": IN, "CS": CS, "CH": CH, "HS": HS, "*": ANY } <NEW_LINE> by_value = dict([(y, x) for x, y in by_string.items()]) <NEW_LINE> @staticmethod <NEW_LINE> def to_string(clas... | Enum of CLASS and QCLASS values
Usage:
>>> Class.IN
1
>>> Class.ANY
255 | 62598f0b3d592f4c4edb9a25 |
class IAnalysisRequestQuery(Interface): <NEW_LINE> <INDENT> pass | Analysis Request query collections | 62598f0b4527f215b58e8a36 |
class UserStrikeMiddleware(object): <NEW_LINE> <INDENT> template_name = 'userstrike/access_blocked.html' <NEW_LINE> def process_request(self, request): <NEW_LINE> <INDENT> if request.user.is_superuser: <NEW_LINE> <INDENT> return <NEW_LINE> <DEDENT> current_user = request.user if request.user.is_authenticated() else Non... | Middleware for blocking access to the website for banned users. | 62598f0bad47b63b2c5a6354 |
class Solution: <NEW_LINE> <INDENT> def maxDiffSubArrays(self, nums): <NEW_LINE> <INDENT> if not nums: <NEW_LINE> <INDENT> return 0 <NEW_LINE> <DEDENT> size = len(nums) <NEW_LINE> leftMax, leftMin = [0 for i in range(size)], [0 for i in range(size)] <NEW_LINE> rightMax, rightMin = [0 for i in range(size)], [0 for i in ... | @param nums: A list of integers
@return: An integer indicate the value of maximum difference between two
Subarrays | 62598f0b283ffb24f3cf23e9 |
class MdLatexExtension (Extension): <NEW_LINE> <INDENT> def __init__(self, *args, **kwargs): <NEW_LINE> <INDENT> self.config = { } <NEW_LINE> super(MdLatexExtension, self).__init__(*args, **kwargs) <NEW_LINE> <DEDENT> def extendMarkdown(self, md, md_globals): <NEW_LINE> <INDENT> self.md = md <NEW_LINE> MD_LATEX_RE = r'... | Class MdLatexExtension extends md by latex | 62598f0b167d2b6e312b5ad8 |
class Ll(list): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> list.__init__(self, [0, 1]) <NEW_LINE> <DEDENT> def __sub__(self, intOrLazyIter): <NEW_LINE> <INDENT> if isinstance(intOrLazyIter, int): <NEW_LINE> <INDENT> return self * intOrLazyIter <NEW_LINE> <DEDENT> return list(intOrLazyIter) <NEW_LINE> <... | a tool for convenient list operate
1. quick exec `list(range(int))` buy ll*int:
>>> ll*4
[0, 1, 2, 3]
2. `ll-Iterable`, `ll/Iterable` is a convenient way to exec `list(Iterable)` | 62598f0ba219f33f346c5369 |
class ResultTable(Table): <NEW_LINE> <INDENT> def __init__(self, h5file, path='/Results', chunksize=None): <NEW_LINE> <INDENT> super(ResultTable, self).__init__(h5file, path, _result_dt, chunksize) <NEW_LINE> <DEDENT> def record_soln(self, soln, soln_uuid, inst_uuid, solver): <NEW_LINE> <INDENT> self.append_data([( sol... | A Cyclopts Table for generic results.
| 62598f0b3346ee7daa336c02 |
class SpeciesFactory(XmlFactory): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> XmlFactory.__init__(self, "pokedex.xml") <NEW_LINE> <DEDENT> def getSpecies(self, speciesName): <NEW_LINE> <INDENT> speciesXML = self.loadSpeciesXML(speciesName) <NEW_LINE> baseExperience = int(speciesXML.findtext(Tags.experie... | Represents the Species Factory | 62598f0b97e22403b3839a1f |
class MediaQuery(graphene.ObjectType): <NEW_LINE> <INDENT> media = graphene.Field(MediaType, id=graphene.ID(), height=graphene.Int(200), width=graphene.Int(200)) <NEW_LINE> def resolve_media(self, info, **args): <NEW_LINE> <INDENT> media = service.fetch(id=args.get("id"), height=args.get("height"), width=args.get("widt... | Media Query,
fetch media entries matching to provided criteria | 62598f0b55399d3f05625064 |
class UNG_831e: <NEW_LINE> <INDENT> events = OWN_TURN_BEGIN.on(Destroy(OWNER)) | Corrupting Mist - (Enchantment)
At the start of the corrupting player's turn, destroy this minion.
https://hearthstone.gamepedia.com/Corrupting_Mist | 62598f0b3d592f4c4edb9a27 |
class InfSampler(Sampler): <NEW_LINE> <INDENT> def __init__(self, data_source, shuffle=False): <NEW_LINE> <INDENT> self.data_source = data_source <NEW_LINE> self.shuffle = shuffle <NEW_LINE> self.reset_permutation() <NEW_LINE> <DEDENT> def reset_permutation(self): <NEW_LINE> <INDENT> perm = len(self.data_source) <NEW_L... | Samples elements randomly, without replacement.
Arguments:
data_source (Dataset): dataset to sample from | 62598f0b7b180e01f3e485e7 |
class StreamAcceptor: <NEW_LINE> <INDENT> def __init__(self, session_name, sam_address=i2plib.sam.DEFAULT_ADDRESS, loop=None): <NEW_LINE> <INDENT> self.session_name = session_name <NEW_LINE> self.sam_address = sam_address <NEW_LINE> self.loop = loop <NEW_LINE> <DEDENT> async def __aenter__(self): <NEW_LINE> <INDENT> se... | Async stream acceptor context manager.
:param session_name: Session nick name
:param sam_address: (optional) SAM API address
:param loop: (optional) Event loop instance
:return: :class:`i2plib.StreamAcceptor` object | 62598f0b5fdd1c0f98e5cadf |
class SystemCronFlow(flow.GRRFlow): <NEW_LINE> <INDENT> frequency = rdfvalue.Duration("1d") <NEW_LINE> lifetime = rdfvalue.Duration("20h") <NEW_LINE> start_time_randomization = True <NEW_LINE> __abstract = True <NEW_LINE> def WriteState(self): <NEW_LINE> <INDENT> if "w" in self.mode: <NEW_LINE> <INDENT> self.Set(self.S... | SystemCronFlows are scheduled automatically on workers startup. | 62598f0ba05bb46b384893b7 |
class TinyMCE(forms.Textarea): <NEW_LINE> <INDENT> def __init__(self, content_language=None, attrs=None, mce_attrs={}): <NEW_LINE> <INDENT> super(TinyMCE, self).__init__(attrs) <NEW_LINE> self.mce_attrs = mce_attrs <NEW_LINE> if content_language is None: <NEW_LINE> <INDENT> content_language = mce_attrs.get('language', ... | TinyMCE widget. Set settings.TINYMCE_JS_URL to set the location of the
javascript file. Default is "MEDIA_URL + 'js/tiny_mce/tiny_mce.js'".
You can customize the configuration with the mce_attrs argument to the
constructor.
In addition to the standard configuration you can set the
'content_language' parameter. It take... | 62598f0b091ae3566870375a |
class Injection(object): <NEW_LINE> <INDENT> def __init__(self, t_inj, t_start, t_stop): <NEW_LINE> <INDENT> self.t_inj = t_inj <NEW_LINE> self.t_start = t_start <NEW_LINE> self.t_stop = t_stop | Class to store information on a given injection.
| 62598f0b71ff763f4b5e62a3 |
class Post(models.Model): <NEW_LINE> <INDENT> title = models.CharField(max_length=200) <NEW_LINE> url = models.CharField(max_length=200, default=None, blank=True) <NEW_LINE> content = models.TextField() <NEW_LINE> pub_date = models.DateTimeField('date published', default=timezone.now) <NEW_LINE> main_image = models.Ima... | User posts | 62598f0bf9cc0f698b1c486f |
class SignatureHasExpired(PermissionDenied): <NEW_LINE> <INDENT> pass | Exception to raise when the signature was valid but has expired. | 62598f0b7b180e01f3e485e8 |
class GridWorldGraphTest(unittest.TestCase): <NEW_LINE> <INDENT> def test(self): <NEW_LINE> <INDENT> graph = grid_world_graph((2, 3)) <NEW_LINE> graph_true = nx.DiGraph() <NEW_LINE> graph_true.add_edges_from(((1, 2), (2, 3), (4, 5), (5, 6)), action=1) <NEW_LINE> graph_true.add_edges_from(((1, 4), (2, 5), (3, 6)), actio... | Test the grid_world_graph function. | 62598f0b3346ee7daa336c04 |
class FractionalDelay(FIRFilterbank): <NEW_LINE> <INDENT> def __init__(self, source, delays, filter_length=None, **args): <NEW_LINE> <INDENT> delays = array(delays) <NEW_LINE> delay_max = amax(abs(delays)) <NEW_LINE> delay_max_int = int(ceil(source.samplerate*delay_max)) <NEW_LINE> if filter_length is None: <NEW_LINE> ... | Filterbank for applying delays which are fractional multiples of the timestep
Initialised with arguments:
``source``
Source sound or filterbank.
``delays``
A list or array of delays to apply (the number of channels in the
filterbank will be equal to the length of this).
``filter_length=None``
Use this... | 62598f0b97e22403b3839a23 |
class VideoUploadsResultSet(ResultSet): <NEW_LINE> <INDENT> def getJSONFromString(self, str): <NEW_LINE> <INDENT> return json.loads(str) <NEW_LINE> <DEDENT> def get_HasNext(self): <NEW_LINE> <INDENT> return self._output.get('HasNext', None) <NEW_LINE> <DEDENT> def get_HasPrevious(self): <NEW_LINE> <INDENT> return self.... | A ResultSet with methods tailored to the values returned by the VideoUploads Choreo.
The ResultSet object is used to retrieve the results of a Choreo execution. | 62598f0b091ae3566870375c |
class ImageBodyIterator(object): <NEW_LINE> <INDENT> def __init__(self, source): <NEW_LINE> <INDENT> self.source = source <NEW_LINE> <DEDENT> def __iter__(self): <NEW_LINE> <INDENT> while True: <NEW_LINE> <INDENT> chunk = self.source.read(CHUNKSIZE) <NEW_LINE> if chunk: <NEW_LINE> <INDENT> yield chunk <NEW_LINE> <DEDEN... | A class that acts as an iterator over an image file's
chunks of data. This is returned as part of the result
tuple from `heat.cfn_client.client.Client.get_image` | 62598f0bf548e778e596a0ca |
class SimReceiver: <NEW_LINE> <INDENT> TIMEOUT = 0.5 <NEW_LINE> PACKET_SIZE = 2048 <NEW_LINE> def __init__(self, address='224.5.23.2', port=10020): <NEW_LINE> <INDENT> self.address = address <NEW_LINE> self.port = port <NEW_LINE> self.logger = logging.getLogger(__name__) <NEW_LINE> self.socket = None <NEW_LINE> <DEDENT... | Used to receive vision packets from grSim | 62598f0bad47b63b2c5a635a |
class JSONConnection: <NEW_LINE> <INDENT> def __init__(self, ws): <NEW_LINE> <INDENT> self.ws = ws <NEW_LINE> <DEDENT> async def send(self, payload: dict): <NEW_LINE> <INDENT> await self.ws.send(json.dumps(payload)) <NEW_LINE> <DEDENT> async def recv(self) -> dict: <NEW_LINE> <INDENT> data = await self.ws.recv() <NEW_L... | Represents a Websocket connection that uses JSON as its payloads. | 62598f0b4527f215b58e8a3c |
class DrawingPosition(ModelSQL, ModelView): <NEW_LINE> <INDENT> __name__ = 'production.drawing.position' <NEW_LINE> drawing = fields.Many2One('production.drawing', 'Drawing', required=True, ondelete='CASCADE') <NEW_LINE> name = fields.Char('Name', required=True) | Production Drawing Position | 62598f0bab23a570cc2d430d |
class Solution: <NEW_LINE> <INDENT> def threeSum(self, numbers): <NEW_LINE> <INDENT> numbers.sort() <NEW_LINE> r = [] <NEW_LINE> for i in range(len(numbers)): <NEW_LINE> <INDENT> j = i + 1 <NEW_LINE> k = len(numbers) - 1 <NEW_LINE> while j < k: <NEW_LINE> <INDENT> total = numbers[i] + numbers[j] + numbers[k] <NEW_LINE>... | @param numbers: Give an array numbers of n integer
@return: Find all unique triplets in the array which gives the sum of zero. | 62598f0b8a349b6b43684d86 |
class Model(Base): <NEW_LINE> <INDENT> __tablename__ = "pytwb_models" <NEW_LINE> model_id = Column(BigInteger, primary_key=True, autoincrement=True) <NEW_LINE> model_name = Column(String(100), nullable=False) <NEW_LINE> model_n_classes = Column(Integer, nullable=False, default=2) <NEW_LINE> model_last_update = Column(D... | Model description | 62598f0ba05bb46b384893bb |
class PincodeOfSchool(KLPDetailAPIView): <NEW_LINE> <INDENT> serializer_class = PincodeSerializer <NEW_LINE> def get_object(self): <NEW_LINE> <INDENT> school_id = self.kwargs.get('pk') <NEW_LINE> school = get_object_or_404(School.objects.all(), id=school_id) <NEW_LINE> return SchoolDetails.objects.get(school_id=school.... | Returns the pincode for the given school
| 62598f0bec188e330fdf73f5 |
class QuarterlyEntityDashboardView(FiscalYearEntityModelDashboardView, QuarterlyReportMixIn): <NEW_LINE> <INDENT> pass | Entity Quarterly Dashboard View. | 62598f0b091ae3566870375e |
class Bugzilla5_2Rest(Bugzilla5_0Rest, Bugzilla5_2): <NEW_LINE> <INDENT> _service = 'bugzilla5.2-rest' | Service for Bugzilla 5.2 REST interface.
API docs: http://bugzilla.readthedocs.io/en/latest/api/index.html | 62598f0b377c676e912f6307 |
class AlertProcessor(markdown.blockprocessors.BlockProcessor): <NEW_LINE> <INDENT> TAGS = { 'info': 'info-circle', 'warning': 'warning', 'danger': 'bomb', } <NEW_LINE> PATTERN = re.compile(r'\[(%s)\]' % '|'.join(TAGS.keys())) <NEW_LINE> def test(self, parent, block): <NEW_LINE> <INDENT> return self.PATTERN.search(block... | Block processor to display alert boxes. | 62598f0b4a966d76dd5eda18 |
class TestCerrarController(BaseTestCase): <NEW_LINE> <INDENT> def test_cerrar_post(self): <NEW_LINE> <INDENT> response = self.client.open('/matriculacion/Cerrar', method='POST') <NEW_LINE> self.assert200(response, "Response body is : " + response.data.decode('utf-8')) | CerrarController integration test stubs | 62598f0bab23a570cc2d430e |
class Bee(Insect): <NEW_LINE> <INDENT> name = 'Bee' <NEW_LINE> damage = 1 <NEW_LINE> watersafe = True <NEW_LINE> def sting(self, ant): <NEW_LINE> <INDENT> ant.reduce_armor(self.damage) <NEW_LINE> <DEDENT> def move_to(self, place): <NEW_LINE> <INDENT> self.place.remove_insect(self) <NEW_LINE> place.add_insect(self) <NEW... | A Bee moves from place to place, following exits and stinging ants. | 62598f0b7b180e01f3e485ea |
class Level(): <NEW_LINE> <INDENT> platform_list = None <NEW_LINE> enemy_list = None <NEW_LINE> underwater = False <NEW_LINE> background = None <NEW_LINE> world_shift = 0 <NEW_LINE> level_limit = -1000 <NEW_LINE> text = None <NEW_LINE> def __init__(self, player): <NEW_LINE> <INDENT> self.platform_list = pygame.sprite.G... | This is a generic super-class used to define a level.
Create a child class for each level with level-specific
info. | 62598f0b50812a4eaa62018e |
class Bounds: <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self.min = Location() <NEW_LINE> self.max = Location() | Represents the two corners of the coordinate system that the spiral
occupies.
The minimums are the bottom-left corner, and the maximums are the
upper-right corner. | 62598f0b167d2b6e312b5ae0 |
class Node: <NEW_LINE> <INDENT> def __init__(self, name): <NEW_LINE> <INDENT> self.name = name <NEW_LINE> self._devices = [] <NEW_LINE> pdir = os.path.abspath(os.path.dirname(sys.argv[0])) <NEW_LINE> logfile = os.path.join( pdir, "log", "{name}-{date}{ext}".format(name=name, date=str(date.today()), ext='.log')) <NEW_LI... | A Node in smartlink corresponds to a network terminal, usually a computer,
to control physical devices. A Node consists of one or multiple Devices.
Node is the basic unit of network communication with control. | 62598f0b5fcc89381b2656cf |
class Patient(object): <NEW_LINE> <INDENT> def __init__(self, viruses, maxPop): <NEW_LINE> <INDENT> self.viruses = viruses <NEW_LINE> self.maxPop = maxPop <NEW_LINE> <DEDENT> def getViruses(self): <NEW_LINE> <INDENT> return self.viruses <NEW_LINE> <DEDENT> def getMaxPop(self): <NEW_LINE> <INDENT> return self.maxPop <NE... | Representation of a simplified patient. The patient does not take any drugs
and his/her virus populations have no drug resistance. | 62598f0b55399d3f0562506c |
class UploadCommand(Command): <NEW_LINE> <INDENT> description = 'Build and publish the package.' <NEW_LINE> user_options = [] <NEW_LINE> @staticmethod <NEW_LINE> def status(s): <NEW_LINE> <INDENT> print('\033[1m{0}\033[0m'.format(s)) <NEW_LINE> <DEDENT> def initialize_options(self): <NEW_LINE> <INDENT> pass <NEW_LINE> ... | Support setup.py upload. | 62598f0b7b180e01f3e485eb |
class TypeValueValuesEnum(_messages.Enum): <NEW_LINE> <INDENT> ALL_INSTANCES_UNHEALTHY = 0 <NEW_LINE> BACKEND_SERVICE_DOES_NOT_EXIST = 1 <NEW_LINE> CAPPED_AT_MAX_NUM_REPLICAS = 2 <NEW_LINE> CUSTOM_METRIC_DATA_POINTS_TOO_SPARSE = 3 <NEW_LINE> CUSTOM_METRIC_INVALID = 4 <NEW_LINE> MIN_EQUALS_MAX = 5 <NEW_LINE> MISSING_CUS... | The type of error returned.
Values:
ALL_INSTANCES_UNHEALTHY: <no description>
BACKEND_SERVICE_DOES_NOT_EXIST: <no description>
CAPPED_AT_MAX_NUM_REPLICAS: <no description>
CUSTOM_METRIC_DATA_POINTS_TOO_SPARSE: <no description>
CUSTOM_METRIC_INVALID: <no description>
MIN_EQUALS_MAX: <no description>
MISSI... | 62598f0bec188e330fdf73f9 |
class RoboclawDiagnostics: <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self.m1_current = None <NEW_LINE> self.m2_current = None <NEW_LINE> self.temp1 = None <NEW_LINE> self.temp2 = None <NEW_LINE> self.main_battery_v = None <NEW_LINE> self.logic_battery_v = None <NEW_LINE> self.error_messages = [] | Holds point-in-time diagnostic values read from the Roboclaw controller.
Diagnostics:
m1_current: Motor 1 current (amps)
m2_current: Motor 2 current (amps)
temp: Roboclaw controller temperature (C)
main_battery_v: Voltage of the main battery (V)
error_messages: List of error messages occuring durin... | 62598f0b0fa83653e46f3a2c |
class Device: <NEW_LINE> <INDENT> def __init__(self, device_id, manufacturer, model, software): <NEW_LINE> <INDENT> self.device_id = device_id <NEW_LINE> self.manufacturer = manufacturer <NEW_LINE> self.model = model <NEW_LINE> self.software = software <NEW_LINE> self.callbacks = {} <NEW_LINE> self.connection = None <N... | Device encapsulates the parameters of a device that is bound to the Server
when running in Infrastructure Mode.
All devices are persisted in the Devices collection, which is a singleton
instance of DeviceCollection. | 62598f0b5fcc89381b2656d0 |
class eMessage: <NEW_LINE> <INDENT> def __init__(self, server, user, **kwargs): <NEW_LINE> <INDENT> self.user = user <NEW_LINE> self.server = server <NEW_LINE> self.folder = kwargs.get('folder', 'INBOX') <NEW_LINE> self.logged_in = False <NEW_LINE> <DEDENT> def login(self, password=None): <NEW_LINE> <INDENT> self.mail ... | Login to mail server to query for emails in rea-only mode | 62598f0b167d2b6e312b5ae2 |
class AuthBaseHandler(tornado.web.RequestHandler, SessionMixin): <NEW_LINE> <INDENT> def initialize(self): <NEW_LINE> <INDENT> self.db = dbSession <NEW_LINE> self.conn = conn <NEW_LINE> <DEDENT> def get_current_user(self): <NEW_LINE> <INDENT> return self.session.get('cookie_name') | 拥有数据库session的base类 | 62598f0b4527f215b58e8a42 |
class Tenant(InfobloxObject): <NEW_LINE> <INDENT> _infoblox_type = 'grid:cloudapi:tenant' <NEW_LINE> _fields = ['cloud_info', 'comment', 'created_ts', 'id', 'last_event_ts', 'name', 'network_count', 'vm_count'] <NEW_LINE> _search_for_update_fields = ['id', 'name'] <NEW_LINE> _updateable_search_fields = ['comment', 'nam... | Tenant: Grid Cloud API Tenant object.
Corresponds to WAPI object 'grid:cloudapi:tenant'
A Tenant object represents an abstract administrative concept in
Cloud Management Platforms, which encompasses all network elements
such as networks, zones, VMs, IP addresses (fixed and floating),
network views, default DNS view, a... | 62598f0b656771135c4881d4 |
class TestSequence(unittest.TestCase): <NEW_LINE> <INDENT> def runTest(self): <NEW_LINE> <INDENT> test_string = ("{DISPLAY_PANEL,86}{SYSTEM_BOARD,90}") <NEW_LINE> bigbuf=oh_big_textbuffer() <NEW_LINE> ep=SaHpiEntityPathT() <NEW_LINE> err = oh_encode_entitypath(test_string, ep) <NEW_LINE> self.assertEqual (err!=None,Tru... | main:
epathstr -> epath test
Test if an entity path string is converted properly into an entity path. | 62598f0bec188e330fdf73fb |
class Meta: <NEW_LINE> <INDENT> app_label = 'huntjob' <NEW_LINE> verbose_name = "工作年限" <NEW_LINE> db_table = "working_years" <NEW_LINE> ordering = ['-create_time'] <NEW_LINE> verbose_name_plural = verbose_name | 重写. | 62598f0b0fa83653e46f3a2e |
class d_EndOfClangError(d_DitError): <NEW_LINE> <INDENT> def __init__(self, clang_name, loc: CodeLocation = None) -> None: <NEW_LINE> <INDENT> super().__init__( _concat("EndOfFileError", f"Unexpected end of {clang_name}"), loc ) | Raised when the end of a class is reached unexpectedly | 62598f0bdc8b845886d52111 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.