Use an Optional<ReplicateRefUpdate> in list()

Using an Optional is safer than using nulls, and made it easy to also
fix the list() API to simply skip things that aren't present instead of
making the API users do that.

Add methods to ReplicateRefUpdate to create the
Optional<ReplicateRefUpdate> instead of creating them inside the list()
method; this helps separate concerns better.

Change-Id: Ib04a59be49d85b289d7dd94b9f2427819324153c
2 files changed
tree: e087515d57b2fc454d3fbf2e51fdf5460bd124ff
  1. .settings/
  2. src/
  3. .gitignore
  4. .mailmap
  5. BUILD
  6. LICENSE