Skip to main content
Best practices
0 votes
6 replies
132 views

I'm developing a winforms application with an underlying database. My system has a BusinessFunction which describes the business functions a user with a given role is able to perform, and the ...
David's user avatar
  • 7
10 votes
1 answer
549 views

If a lambda is capture-less, its closure type has conversion operator to function pointer. For example, auto l = []{}; using F = decltype(+l); //pointer to function type constexpr F p = l; And if a ...
Fedor's user avatar
  • 25.4k
Best practices
0 votes
3 replies
47 views

In a VB.Net WPF XAML project, I want to add a Property to a UserControl class and inherit from that Class. I have tried the following: Public Class clsUcBase Inherits UserControl Private ...
DSchmidt's user avatar
3 votes
1 answer
155 views

I am having trouble understanding/fixing a problem I am encountering in my first attempt to create a derived container from an abstract superclass. It seems that I cannot access the derived class's ...
Sir Is-Ikke Null-a-ton's user avatar
2 votes
1 answer
107 views

I have this interface: public interface IDebugEndPoint { void InstructionReady(ICPU cpu); } where ICPU is implemented by many concrete CPU types. I pass an IDebugEndPoint to an ICPU for "...
n8wrl's user avatar
  • 19.9k
0 votes
2 answers
55 views

I have a custom module which defines a model which inherits res.partner (delegation) using inherits on partner_id field, like this: from odoo import fields, models class CustomModel(models.Model): ...
qdev's user avatar
  • 1,459
3 votes
1 answer
87 views

Suppose I have a bunch of generic Herbivore types, each coupled with a specific Vegetable type which it knows to consume. Further suppose I want to be able to dump any generic vegetable onto any ...
user3023433's user avatar
1 vote
2 answers
68 views

I'm trying to load a type from an assembly at runtime that implements this interface which is in a project called PluginBase: type IPlugin = abstract member TestString: Option<string> with ...
JackEncore's user avatar
Advice
2 votes
3 replies
85 views

In java we have abstract classes and interfaces where we declare set of methods that will exist on objects that conform when interacting with implementations of that type abstract class Foo { ...
Dragas's user avatar
  • 1,290
0 votes
1 answer
72 views

I’m learning Object-Oriented Programming in JavaScript and got confused by the following code: class Animal { constructor(lg) { this.legs = lg; } } class Dog extends Animal { constructor() {...
sylvesterChase's user avatar
1 vote
2 answers
157 views

How could I code a hierarchy of SQL DOMAINs without duplicating the code for the root SQL domain (thus implementing inheritance)? E.g., here is a hierarchy of SQL domains: text advise comment name ...
Alexandre Bailly's user avatar
Best practices
0 votes
3 replies
72 views

I’ve searched the space of Python nested class inheritance and have read that it's not best practice. I have a NameError on the following: class A() pass class B(A) pass I indeed ...
Mushy's user avatar
  • 2,711
1 vote
2 answers
162 views

I would like to know the proper way to get the following code to work. With inheritance, you can call the function of a parent pointer and execute the child function. But, if there are two parent ...
Foivos Antoulinakis's user avatar
Advice
1 vote
3 replies
155 views

We're using an attribute, which looks somewhat like this (simplified): unit SomeProject.ThreadLibrary.Attributes; interface type ThreadAffinityAttribute = class (TCustomAttribute) ...
Valerian K.'s user avatar
0 votes
1 answer
89 views

I'm testing SwiftData model inheritance (new in iOS 26) and encountering a crash when combining: A model that inherits from another model A separate model with relationships to the parent class ...
simnik's user avatar
  • 483

15 30 50 per page
1
2 3 4 5
2860