Skip to content

Design: CreatableImpl should not assume it's Resource #972

Description

@anuchandy

CreatableImpl represents ANY type that can be created not only the types that implements Resource. https://github.com/Azure/azure-sdk-for-java/blob/master/azure-mgmt-resources/src/main/java/com/microsoft/azure/management/resources/fluentcore/model/implementation/CreatableImpl.java#L32

The below typecast (Creatable<? extends Resource>) this results null for the create-able type that does not extends from Resource.

    protected CreatableImpl(String name, InnerModelT innerObject) {
        super(name, innerObject);
        creatableTaskGroup = new CreatableTaskGroup(name, (Creatable<? extends Resource>) this, this);
    }

ResourceImpl is one type that inherits from CreatableImpl that does not mean thats the only one.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions