001/* 002 * Licensed to the Apache Software Foundation (ASF) under one or more 003 * contributor license agreements. See the NOTICE file distributed with 004 * this work for additional information regarding copyright ownership. 005 * The ASF licenses this file to You under the Apache License, Version 2.0 006 * (the "License"); you may not use this file except in compliance with 007 * the License. You may obtain a copy of the License at 008 * 009 * http://www.apache.org/licenses/LICENSE-2.0 010 * 011 * Unless required by applicable law or agreed to in writing, software 012 * distributed under the License is distributed on an "AS IS" BASIS, 013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 014 * See the License for the specific language governing permissions and 015 * limitations under the License. 016 */ 017package org.apache.juneau; 018 019import java.util.*; 020 021import org.apache.juneau.annotation.*; 022 023/** 024 * Same as {@link BeanMeta}, except the list of bean properties are limited by a {@link Beanp#properties() @Beanp(properties)} annotation. 025 * 026 * <h5 class='section'>See Also:</h5><ul> 027 028 * </ul> 029 * 030 * @param <T> The class type that this metadata applies to. 031 */ 032public class BeanMetaFiltered<T> extends BeanMeta<T> { 033 034 /** 035 * Wrapper constructor. 036 * 037 * @param innerMeta The untransformed bean meta of the bean property. 038 * @param pNames The list of transformed property names. 039 */ 040 public BeanMetaFiltered(BeanMeta<T> innerMeta, String[] pNames) { 041 super(innerMeta.classMeta, innerMeta.ctx, innerMeta.beanFilter, pNames, null); 042 } 043 044 /** 045 * Wrapper constructor. 046 * 047 * @param innerMeta The untransformed bean meta of the bean property. 048 * @param pNames The list of transformed property names. 049 */ 050 public BeanMetaFiltered(BeanMeta<T> innerMeta, Collection<String> pNames) { 051 this(innerMeta, pNames.toArray(new String[pNames.size()])); 052 } 053}