Skip to main content
Filter by
Sorted by
Tagged with
0 votes
0 answers
80 views

I wanted to create a flexible MessageProcessor, depending on the SupplierType(= enum) and depending on which MessageProcessor comes out a different Message-object will be used. The current situation ...
zhrgci's user avatar
  • 716
2 votes
1 answer
60 views

Pressing Ctrl+F12 displays the file structure with a list of all fields and methods. Is it possible to change the sorting of this list so that the fields are displayed first and then the methods? The ...
Arvalon's user avatar
  • 121
0 votes
2 answers
680 views

In iOS 26, the UISplitViewController primary or detail ViewController is displayed in modal mode, which is not correct. How to remove it? Code for my UISplitViewController subclass: override func ...
Mikhail S's user avatar
  • 4,100
-5 votes
2 answers
176 views

I'm writing a program that is very sensitive to garbage collection so I'm trying to avoid allocating to the heap after initialization. In the example below, calling Run() will allocate to the heap ...
ATD's user avatar
  • 892
1 vote
2 answers
193 views

I've tried looking up more specifics on this online but haven't found much info on this topic. I'm reading about generic interfaces from the C# documentation and everything seems reasonable until I ...
immediate_wreckage's user avatar
1 vote
4 answers
100 views

I have a Blazor server-side app where I use DynamicComponent on a page to create and add components at runtime. To do this I have the following: A set of interfaces: public interface IGetData { ...
Ivan Debono's user avatar
  • 1,016
1 vote
1 answer
89 views

I have a bunch of types that implements a Equal(other myType) method for comparison against other values of the same type. These types are used as map values and I wish to compare map equality using ...
F21's user avatar
  • 33.6k
2 votes
3 answers
114 views

// types.ts export interface InterfaceCard { value: number; suit: string; getName(): string; } export interface InterfacePlayer { handCards: InterfaceCard[]; receiveCard(card: InterfaceCard)...
Sameer Dayer's user avatar
0 votes
0 answers
132 views

I'm trying to create a simple extension for Directus which adds a button at the header on collection list page (a button nearby "+" button) When a user selects some of collection items, then ...
June's user avatar
  • 61
0 votes
0 answers
64 views

I am writing a TypeScript application in Visual Studio. However, when I try to use the roundRect method associated with the Canvas 2D API, I get the compilation error: TS2339: (TS) Property '...
Martin Vaughan's user avatar
-1 votes
1 answer
137 views

I try to understand the correct usage of reflection with a struct compose by nested structs that implement an interface on Golang; Here the code: package main import ( "log" "...
Ziphon's user avatar
  • 31
0 votes
2 answers
94 views

Just getting in to interfaces and I can't seem to find how to implement calculated fields... I know I can do this in the deriving class, but is there a way to do this in the interface itself? A very ...
Richard Harrison's user avatar
2 votes
1 answer
91 views

My intention was to replace the following snippet: List<List<String>> lists; for (int i = 0; i < n; i++) lists.add(new ArrayList<String>()); with Stream API one-liner: List&...
Alex G's user avatar
  • 41
0 votes
0 answers
50 views

I know the concept of schemas and how we use it when designing FastAPI applications. For example from pydantic import BaseModel class User(BaseModel): username: str email: str age: int ...
KansaiRobot's user avatar
  • 10.6k
1 vote
0 answers
75 views

I have a WIT compatible Web Assembly Component Model based module written in JAVASCRIPT/TYPESCRIPT and exposed as a WASM using jco and further transpiled to run in the browser. I have 2 questions in ...
Tarun Patel's user avatar
0 votes
1 answer
90 views

I have a basic interface, which I use down the line to enforce specific values on other interfaces: interface ObjectWithEnforcedValues { values: readonly EnforcedValue[]; } enum EnforcedValue { ...
Tom's user avatar
  • 225
-1 votes
2 answers
36 views

I'm working on a terminal game based on this card game that gets its cards from deckofcardsapi.com. Cards are stored in a struct named Card in a package called card and each Card is stored in a struct ...
wavesinaroom's user avatar
3 votes
0 answers
108 views

Is the following a .NET 8 / C# bug? internal class Program { interface IGetString { string GetString(); } class A : IGetString { public string GetString() => &...
Sergey Gussak's user avatar
0 votes
3 answers
114 views

Here is my interface. public interface IFoo { TOut Process<TOut, TIn>(SomeClass<TOut, TIn> container) where TOut : class, where TIn : class; } I would like to achieve ...
Ihor Marenych's user avatar
2 votes
3 answers
111 views

SuperService: package service; public interface SuperService { } CustomerService: package service.custom; import dto.Customer; import java.util.List; public interface CustomerService{ boolean ...
Sonny Mad's user avatar
1 vote
1 answer
80 views

I'm trying to implement interface for Node class in CSharp. NodeInterfaces.cs public interface INode<T> { T Value { get; set; } Node<T> Left { get; set; } Node<T> Right { ...
Базакин Егор's user avatar
1 vote
1 answer
76 views

I have the following interface which contains a static method definition: public interface IUpgradableDataSource { static abstract Task<JsonElement> UpgradeSourceConfigurationAsync( ...
Apollo3zehn's user avatar
1 vote
1 answer
61 views

Say I have a const type and corresponding sub types - type Animaltype int32 const ( dogs Animaltype = iota cats ) type dogtype int32 const ( retriever dogtype = iota whippet )...
thefrollickingnerd's user avatar
3 votes
1 answer
84 views

Let's assume we have two interfaces: interface A { name: string; _id?: string; } interface B { name: string; _id: string; } When assigning them to each other, typescript behaves like I would ...
user avatar
4 votes
1 answer
110 views

I have a public interface. One of its methods is marked internal. And it has to be - it takes an argument that is an internal type. I write a public class that implements this interface, I do so via a ...
PreventRage's user avatar

1
2 3 4 5
403