Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
io.gs2.csharp.cdk / Core / Func / GetAttr.cs
Size: Mime:
using Gs2Cdk.Core.Model;

namespace Gs2Cdk.Core.Func
{
    public class GetAttr : IFunc
    {
        
        private readonly string _key;

        public GetAttr(
            CdkResource resource,
            string path,
            string key
        ) {
            if (key != null) {
                this._key = key;
            } else {
                this._key = resource.ResourceName + "." + path;
            }
        }

        public string Str() {
            return "!GetAttr " + this._key;
        }

        public static GetAttr Region() {
            return new GetAttr(
                null,
                null,
                "Gs2::Region"
            );
        }

        public static GetAttr OwnerId() {
            return new GetAttr(
                null,
                null,
                "Gs2::OwnerId"
            );
        }
    }
}