Skip to content

Cannot access schema when creating custom IJoinedSubclassConvention implementation #319

@stackh34p

Description

@stackh34p

Currently I am in need of implementing the IJoinedSubclassConvention where I need to override the schema, by deriving from the original schema name. The IJoinedSubclassInstance interface exposes a Schema method for that, but it does not allow you to access the current value of the schema.

For reference, it is possible when implementing IClassConvention to access the member Schema by the following line:
var schema = ((IClassInspector) instance).Schema;, where instance is the IClassInstance object.

Doing so with IJoinedSubclassInstance as follows:
var schema = ((IJoinedSubclassInspector) instance).Schema;
does not work, as there is no such property, nor it seems that the IJoinedSubclassInstance exposes that in any other way. Thus, I was forced to use reflection to get my thing done.

I think there should be a Schema property there, for the sake of consistency with the other convention interfaces which are applicable.


I am willing to personally provide a patch if you would agree such functionality is necessary in the future development of the project.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions