Re: Getting object properties from interface reference

From: Andrey (leyandrew_at_yahoo.com)
Date: 09/17/04


Date: Fri, 17 Sep 2004 03:37:50 GMT

Peter Rilling wrote:
> You could try using reflection, but you will not be able to early bind your
> method calls because, as you are aware, the compiler only sees the interface
> members.
>

I got your idea! But still,... how does VS sees properties of user components?
Or is there any around? Maybe attributes?

What i'm doing is a IDE for a python reporting package. This IDE has the same idea as VS IDE - set
of reporting components which you can drop onto a page, and for each of which you should be able to
set some properties, which obviously are differ by component class

Please any ideas!!!

Thank you in advance
Andrey

> "Andrey" <leyandrew@yahoo.com> wrote in message
> news:Drp2d.57093$MQ5.10885@attbi_s52...
>
>>Hi,
>>
>>Here's the problem:
>>Say a have a class, implementing an interface:
>>
>>// vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
>>public class GraphClass : IGraphInterface
>>{
>>public string Property1 {
>>get {
>> return value1;
>>}
>>set {
>> value1 = value; }
>>}
>>
>>public string Property2 {
>>get {
>> return value2;
>>}
>>set {
>> value2 = value; }
>>}
>>/*Some other code*/
>>}
>>// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>>
>>Say, somewhere in my progarm i do the following:
>>
>>IGraphInterface gc = new GraphClass();
>>
>>Is there a way to get a list of properties (Property1, Property2, etc)
>>along with their names
>>(if possible) from the instance 'gc', if it's referenced as interface,
>>like in the example?
>>I can assume that yes, because it's done somehow by VS IDE, when you use
>>UserControls, where you can define a property which will appear in
>>"Properties" toolbar.
>>
>>
>>Any ideas would be highly appreciated!
>>
>>Thank you in advance,
>>Andrey
>
>
>



Relevant Pages

  • Re: From the LuxAsm list.
    ... > create an IDE, but would create a LuxAsm mode for emacs. ... only a user interface thing... ... accessed via a command-line interface _separately_ and _independently_ to ... LuxAsm will operate in the same exact method _except_ simply that the "user ...
    (alt.lang.asm)
  • [git patches] IDE updates part 1
    ... Since it's "Merging Spree" again here goes the first IDE update for 2.6.26: ... ability to add new interfaces for ide-generic host driver through ... -hd.c will normally be allowed to control the primary IDE interface. ... int boot_cpuid_phys; ...
    (Linux-Kernel)
  • RE : Re: [RFC] ATA host-protected area (HPA) device mapper?
    ... they are not IDE register compatible. ... interface copying exercise that caught on. ... provide ATA taskfiles but afaik not the boot loader unfortunately. ... It is mainly to increase the bandwidth of the pipe linking the hard disk to the ...
    (Linux-Kernel)
  • [git patches] IDE updates part #2
    ... IDE updates continued: ... IDE ATAPI streaming tape driver ... tristate "ICS IDE interface support" ... static int __devinit ...
    (Linux-Kernel)
  • [PATCH] Configure IDE probe delays
    ... IDE initialization and probing makes numerous calls to sleep for 50 ... The value is probably rather conservative for modern hardware: ... where these delays may constitute a large ... would be to configure the value in the IDE interface and device drivers ...
    (Linux-Kernel)