/** * Narrows this feed using categories with an appropriate kind value. * This will loop through the categories, checking if they represent kinds, * and adapting the feed to that kind if an appropriate adaptation was * found. This will return the most specific subtype of the narrowed type. */ @Override protected Element narrow(ElementMetadata<?,?> meta, ValidationContext vc) { String kind = Kinds.getElementKind(this); if (kind != null) { return adapt(this, meta, kind); } return super.narrow(meta, vc); }
/** * Narrows this feed using categories with an appropriate kind value. * This will loop through the categories, checking if they represent kinds, * and adapting the feed to that kind if an appropriate adaptation was * found. This will return the most specific subtype of the narrowed type. */ @Override protected Element narrow(ElementMetadata<?,?> meta, ValidationContext vc) { String kind = Kinds.getElementKind(this); if (kind != null) { return adapt(this, meta, kind); } return super.narrow(meta, vc); }
/** * Narrows this entry using categories with an appropriate kind value. This * will loop through the categories, checking if they represent kinds, and * adapting the entry to that kind of an appropriate adaptation was found. * This will return the most specific subtype of the narrowed type that could * be found. */ @Override protected Element narrow(ElementMetadata<?, ?> metadata, ValidationContext vc) { String term = Kinds.getElementKind(this); if (term != null) { return adapt(this, metadata, term); } return super.narrow(metadata, vc); } }
/** * Narrows this entry using categories with an appropriate kind value. This * will loop through the categories, checking if they represent kinds, and * adapting the entry to that kind of an appropriate adaptation was found. * This will return the most specific subtype of the narrowed type that could * be found. */ @Override protected Element narrow(ElementMetadata<?, ?> metadata, ValidationContext vc) { String term = Kinds.getElementKind(this); if (term != null) { return adapt(this, metadata, term); } return super.narrow(metadata, vc); } }