8000 fruit Usage inquiries · Issue #169 · google/fruit · GitHub
[go: up one dir, main page]

Skip to content

fruit Usage inquiries #169

Open
Open

Description

@yuansunliang1988

Can you provide a demo that supports the following features? In terms of the hello inheritance system

  1. support for multiple and single instances, greeterimpl for multiple instances and stdoutwriter for single instances
  2. support external access to stdoutwriter, not limited to greeterimpl internal use.

thanks

Activity

  1. poletti-marco commented on May 13, 2025

    @poletti-marco
    Contributor

    Hi, if you're trying to do something specific, it would help if you describe what you're trying to achieve, to avoid falling into the XY problem (see xyproblem.info), what you tried and what happened (errors, or parts of the code that you don't know how to complete).

    For the first one, maybe you want to use annotated injection, as in https://github.com/google/fruit/wiki/tutorial:-annotated-injection ?

    For the 2nd one, note that you can install a get*Component function in multiple components if it's needed in more than 1 place. It's still a singleton.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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

      0