@Override
        public Value evaluate(List<Value> arguments) {
            String regionName = arguments.get(0).expectStringValue().getValue();
            Partition matchedPartition;
            boolean inferred = false;

            // Known region
            matchedPartition = REGION_MAP.get(regionName);

            if (matchedPartition == null) {
                matchedPartition = findPartition(regionName);
                if (matchedPartition != null) {
                    inferred = true;
                }
            }

            if (matchedPartition == null) {
                throw new RuntimeException("Unable to match a partition for region " + regionName);
            }

            PartitionOutputs matchedPartitionOutputs = matchedPartition.getOutputs();
            return Value.recordValue(MapUtils.of(
                    NAME,
                    Value.stringValue(matchedPartition.getId()),
                    DNS_SUFFIX,
                    Value.stringValue(matchedPartitionOutputs.getDnsSuffix()),
                    DUAL_STACK_DNS_SUFFIX,
                    Value.stringValue(matchedPartitionOutputs.getDualStackDnsSuffix()),
                    SUPPORTS_FIPS,
                    Value.booleanValue(matchedPartitionOutputs.supportsFips()),
                    SUPPORTS_DUAL_STACK,
                    Value.booleanValue(matchedPartitionOutputs.supportsDualStack()),
                    INFERRED,
                    Value.booleanValue(inferred),
                    IMPLICIT_GLOBAL_REGION,
                    Value.stringValue(matchedPartitionOutputs.getImplicitGlobalRegion())));
        }
A {@link FunctionDefinition} for the {@link AwsPartition} function.
smithy-aws-endpoints/src/main/java/software/amazon/smithy/rulesengine/aws/language/functions/AwsPartition.java