Skip to content

mgmt, provide default method for fluent interfaces #3119

@weidongxu-microsoft

Description

@weidongxu-microsoft

In this case, we should generate new interface methods with default. One option is to return null, which may not be valid response but it would be better to throw UnsupportedOperationException with clear message. Throwing exception will also work for operations that return void and indicate to the user something didn't work as expected.

For generated libs, we probably don't want to bother comparing it with prior version to see which method was added to interface. It likely easier to just generate all interface with a default method, which throws UnsupportedOperationException.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions