Questions tagged [interface-implementation]
137 questions
2
votes
4 answers
Implementing an interface and extending a class of a different project
This doubt has been bugging me for quite sometime now.
I'll try to present it in the form of following scenario.
Scenario -
Assume I have 2 different projects, Project-1 and Project-2, in the same Workspace in Eclipse-JUNO. Project-1 has an…

Anirudh Sharma
- 115
- 3
- 15
1
vote
0 answers
System.NotImplementedException after trying to run canvas.DrawText in .NET MAUI
I'm trying to draw some markdown on a GraphicsView in .NET MAUI 7. Visual Studio is telling me that the function that draws markdown - canvas.DrawText - is not implemented.
I installed the NuGet package Microsoft.Maui.Graphics.Text.Markdig just as…

Miodek
- 55
- 5
1
vote
0 answers
How to auto-generate an interface implementation in vscode
auto-generate an interface implementation in Visual Studio Code
I know this is quite lazy but, is there any way on Visual Studio Code to auto-generate an interface implementation? (I don't mean at runtime but at design time, like a code snippet).…

Maximiliano Neves
- 11
- 2
1
vote
1 answer
How can i allow the thread which is an implementation of interface to communicate with the JWindow objects?
How can i get the Network counter value to include in my Main JButton goal? I was doing something like this:
Main.java:
package demo;
import java.awt.BorderLayout;
import java.util.logging.Level;
import java.util.logging.Logger;
import…
user285594
1
vote
1 answer
Set test device programmatically
How and where do I implement the code to set my test device ID for Admob in Flutter apart from setting it in my ADMOB UI? This line "Use RequestConfiguration.Builder().setTestDeviceIds(Arrays.asList("myTestDeviceId"))" keeps popping

afolabi emmanuel
- 11
- 1
1
vote
2 answers
How to implement an F# interface with a member returing an instance of that interface?
Let's say I have the following interface in F#:
type InterfaceA =
abstract Magic : InterfaceA -> InterfaceA
How can I implement such interface?
When I try to do it like this:
type MyTypeA = {x:int} with
interface InterfaceA with
member…

zajer
- 649
- 6
- 17
1
vote
1 answer
(OOP) Implementing a pre-programmed function in a class
An experimental/theoretical question concerning any OOP language (Java, C#, Typescript, etc..)
Usually, when implementing an interface in a class, one has to override all the functions of that interface in the class by having to write the code for…

Wassim Tahraoui
- 159
- 14
1
vote
1 answer
Java implementing interface Cloneable on a inheritance structure
I got the following Questions on my code:
public class Parent {
...
}
public class Child extends Parent implements Cloneable {
...
@Override
public Child clone() {
return new Child() //deep copy
}
}
Here are my…

IsteveI
- 19
- 4
1
vote
0 answers
How to check if a Java interface has an implementation?
Is it possible in Java to check if an interface has been implemented?
If yes:
Is there an official way to do this?
How is it possible?
And is it possible to check if it is implemented in an external library (jar)?
If no:
Is there a workaround to…

Zig Razor
- 3,381
- 2
- 15
- 35
1
vote
0 answers
Transport Layer Security (TLS 1.3) with .NET framework 4.8
We are using two project
CommonInterFaces (Developed using .NET 4)
InterfaceImplementation (Recompile using .NET 4.8)
Previously we were using TLS 1.2, but it will eventually be replaced by the newest released standard TLS 1.3.
For same reason we…

Deepak
- 112
- 10
1
vote
1 answer
Why am I getting: The type 'IThirdParty' is defined in an assembly that is not referenced. You must add a reference to assembly 'ThirdPartyAssembly'?
Suppose there is third party assembly ThirdPartyAssembly.dll that expose following:
namespace ThirdPartyAssembly
{
public interface IThirdParty
{
void GetInstance(ThirdPartyInfo info);
}
public class ThirdPartyInfo
{
…

Tim
- 398
- 2
- 6
- 13
1
vote
1 answer
WebAPI Model [ModelBinder] with interface class while specifying implementation
Is it possible to pass into the ModelBinder which implementation you want to use inline?
Given the following definitions:
public interface ISomeInterface
{
string MyString{get;set;}
}
public class SomeInterfaceImplementation_One :…

Watson
- 1,385
- 1
- 15
- 36
1
vote
1 answer
When implementing an interface, how do you implement an indexer property?
I'm working with a COM API that was created in another language, and I'm accessing it with C#. I'm trying to implement one of the interfaces, but I'm seeing an error in VS that says:
'MyClass' does not implement interface member…

Tester101
- 8,042
- 13
- 55
- 78
1
vote
3 answers
How to know which bean was injected into interface?
So I have a set packages that are my base code for extended applications. My application implements a series of interfaces that then are inject by spring during run time (As configured). I would like to know is there is a way that I could know which…

jfzr
- 374
- 4
- 17
1
vote
1 answer
How to implement different accessibility modifiers when I implement the interface
I want to create an interface with property which has different accessibility modifiers in derived classes, like:
public interface IPrisoner
{
string PrisonerName { get; set; }
}
public class Prisoner : IPrisoner
{
public string…

Oleg Sh
- 8,496
- 17
- 89
- 159