pulumi/pkg/resource
joeduffy db99092334 Implement mapper.Encode "for real"
This change implements `mapper.Encode` "for real" (that is, in a way
that isn't a complete embarrassment).  It uses the obvious reflection
trickery to encode a tagged struct and its values as a JSON-like
in-memory map and collection of keyed values.

During this, I took the opportunity to also clean up a few other things
that had been bugging me.  Namely, the presence of `mapper.Object` was
always error prone, since it isn't a true "typedef" in the sence that
it carries extra RTTI.  Instead of doing that, let's just use the real
`map[string]interface{}` "JSON-map-like" object type.  Even better, we
no longer require resource providers to deal with the mapper
infrastructure.  Instead, the `Check` function can simply return an
array of errors.  It's still best practice to return field-specific errors
to facilitate better diagnostics, but it's no longer required; and I've
added `resource.NewFieldError` to eliminate the need to import mapper.

As of this change, we can also consistently emit RPC structs with `lumi`
tags, rather than `lumi` tags on the way in and `json` on the way out.

This completes pulumi/lumi#183.
2017-06-05 17:49:00 -07:00
..
idl Make updates work in the face of output properties 2017-06-01 10:09:52 -07:00
analyzer.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
analyzer_plugin.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
asset.go Modify provider creates; use get for outs 2017-06-01 08:36:43 -07:00
check.go Implement mapper.Encode "for real" 2017-06-05 17:49:00 -07:00
config.go Initial support for output properties (1 of 3) 2017-06-01 08:32:12 -07:00
context.go Create a plan plugin host 2017-06-01 11:41:24 -07:00
deployment.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
env.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
plan.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
plan_graph.go Reclassify Lumi under the Apache 2.0 license 2017-05-18 14:51:52 -07:00
plan_test.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
plugin.go Alter diag.Message to discourage format mistakes 2017-06-02 18:37:28 -07:00
properties.go Implement mapper.Encode "for real" 2017-06-05 17:49:00 -07:00
properties_diff.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
properties_diff_test.go Add some property diff tests 2017-06-01 15:36:22 -07:00
provider.go Make updates work in the face of output properties 2017-06-01 10:09:52 -07:00
provider_host.go Fix two lint issues that crept in 2017-06-02 09:05:10 -07:00
provider_plugin.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
resource.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
resource_graph.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
rpc.go Store both input and output properties distinctly 2017-06-04 19:24:48 -07:00
snapshot.go Create a plan plugin host 2017-06-01 11:41:24 -07:00
stable.go Reclassify Lumi under the Apache 2.0 license 2017-05-18 14:51:52 -07:00
urn.go Reclassify Lumi under the Apache 2.0 license 2017-05-18 14:51:52 -07:00