Clones the class info, but changes access, setting deprecated flag.

@param classInfo
the original class info
@return the cloned and deprecated info.
3284
private static ClassInfo cloneDeprecated(ClassInfo classInfo) {
	return new ClassInfo(classInfo.getVersion(), classInfo.getAccess()
		| Opcodes.ACC_DEPRECATED, classInfo.getName(),
		classInfo.getSignature(), classInfo.getSupername(),
		classInfo.getInterfaces(), classInfo.getMethodMap(),
		classInfo.getFieldMap());
    }
627891
public Class<?> getDomainClass(Class<?> toClass) {
        Class<?> declaredClass = getDeclaredDomainClass(toClass);
        return classReplacer.replaceClass(declaredClass);
    }
817647
private function convertToClassMetadataInfo($className, $mappingInformation)
    {
        $metadata = new ClassMetadataInfo($className);

        $this->convertTableName($className, $mappingInformation, $metadata);
        $this->convertColumns($className, $mappingInformation, $metadata);
        $this->convertIndexes($className, $mappingInformation, $metadata);
        $this->convertRelations($className, $mappingInformation, $metadata);

        return $metadata;
    }
607909
private ClassInfo classInfoForUnnamed(ClassTemplateSpec enclosingClass, String name, DataSchema schema)
  {
    assert !(schema instanceof NamedDataSchema);
    assert !(schema instanceof PrimitiveDataSchema);

    final ClassInfo classInfo = classNameForUnnamedTraverse(enclosingClass, name, schema);
    final String className = classInfo.fullName();

    final DataSchema schemaFromClassName = _classNameToSchemaMap.get(className);
    if (schemaFromClassName == null)
    {
      final ClassTemplateSpec classTemplateSpec = createFromDataSchema(schema);

      if (enclosingClass != null && classInfo.namespace.equals(enclosingClass.getFullName()))
      {
        classTemplateSpec.setEnclosingClass(enclosingClass);
        classTemplateSpec.setClassName(classInfo.name);
        classTemplateSpec.setModifiers(ModifierSpec.PUBLIC, ModifierSpec.STATIC, ModifierSpec.FINAL);
      }
      else
      {
        classTemplateSpec.setNamespace(classInfo.namespace);
        classTemplateSpec.setClassName(classInfo.name);
        classTemplateSpec.setModifiers(ModifierSpec.PUBLIC);
      }
      classInfo.definedClass = classTemplateSpec;
    }
    else
    {
      checkForClassNameConflict(className, schema);
      classInfo.existingClass = _schemaToClassMap.get(schemaFromClassName);
    }

    return classInfo;
  }
297490
public Map<String, ClassInfo> getAllClassesAsMap() {
        if (closed.get()) {
            throw new IllegalArgumentException("Cannot use a ScanResult after it has been closed");
        }
        if (!scanSpec.enableClassInfo) {
            throw new IllegalArgumentException("Please call ClassGraph#enableClassInfo() before #scan()");
        }
        return classNameToClassInfo;
    }
1323765
public RequestViewMetadata cloneInstance()
    {
        RequestViewMetadata rvm = new RequestViewMetadata();
        rvm.initialProcessedClasses = new HashMap<Class<?>, Boolean>(
                this.initialProcessedClasses != null ? 
                    this.initialProcessedClasses : this.processedClasses);
        if (this.initialAddedResources != null)
        {
            rvm.initialAddedResources = new HashMap<ResourceDependency, Boolean>(
                    this.initialAddedResources);
        }
        else if (this.addedResources != null)
        {
            rvm.initialAddedResources = new HashMap<ResourceDependency, Boolean>(
                    this.addedResources);
        }
        return rvm;
    }
475619
public ClassInfoList getAnnotations() {
        return filter(new ClassInfoFilter() {
            @Override
            public boolean accept(final ClassInfo ci) {
                return ci.isAnnotation();
            }
        });
    }
57812
private function newInstance($classInfo)
    {
        $className = is_array($classInfo) ? array_shift($classInfo) : (is_string($classInfo) ? $classInfo : '');
        $parameters = is_array($classInfo) ? $classInfo : array($this->container->getParameter('behat.context.parameters'));

        $reflection = new \ReflectionClass($this->prefixRootNamespace($className));

        if (!$reflection->hasMethod('__construct')) {
            $parameters = array();
        }

        return $reflection->newInstanceArgs($parameters);
    }
254894
public <S extends T> TypeDeserializationInfo<T> addTypeInfo( Class<S> clazz, String typeInfo ) {
        typeInfoToClass.put( typeInfo, clazz );
        return this;
    }
858649
public final Method getMetaInfo() {
		for(Class<?> c=getClass(); c != null; c=c.getSuperclass()) {
			Method a = c.getAnnotation(Method.class);
			if(a != null) {
				return a;
			}
		}
		
		throw new IllegalArgumentException("Neither "+getClass()+" nor its superclasses are annotated with "+Method.class);
	}
1027185
public void copyClassHelp()
    {
        Record recClassInfo = this.getMainRecord();
        
        Record recClassInfo2 = new ClassInfo(this);
        recClassInfo2.setKeyArea(ClassInfo.CLASS_NAME_KEY);

        try   {
            recClassInfo.setKeyArea(ClassInfo.ID_KEY);
            recClassInfo.close();
            while (recClassInfo.hasNext())
            {
                recClassInfo.next();
                String strClassReference = recClassInfo.getField(ClassInfo.COPY_DESC_FROM).toString();
                if ((strClassReference != null) && (strClassReference.length() > 0))
                {
                    recClassInfo2.getField(ClassInfo.CLASS_NAME).setString(strClassReference);
                    if (recClassInfo2.seek(null))
                    {
                        recClassInfo.edit();
                        if (!recClassInfo2.getField(ClassInfo.CLASS_DESC).isNull())
                            recClassInfo.getField(ClassInfo.CLASS_DESC).moveFieldToThis(recClassInfo2.getField(ClassInfo.CLASS_DESC));
                        recClassInfo.getField(ClassInfo.CLASS_EXPLAIN).moveFieldToThis(recClassInfo2.getField(ClassInfo.CLASS_EXPLAIN));
                        recClassInfo.getField(ClassInfo.CLASS_HELP).moveFieldToThis(recClassInfo2.getField(ClassInfo.CLASS_HELP));
                        recClassInfo.set();
                    }
                }
            }
        } catch (DBException ex)    {
            ex.printStackTrace();
        } finally {
            recClassInfo2.free();
        }
    }
539008
private void obtainClassInfoRecursive(final Set<ClassInfo> reachableClassInfo) {
        reachableClassInfo.addAll(memberClassNameToClassInfo.values());
        for (final PackageInfo subPackageInfo : getChildren()) {
            subPackageInfo.obtainClassInfoRecursive(reachableClassInfo);
        }
    }
58836
public @Nonnull
    ClassDescriptor getClassDescriptor(@SlashedClassName String className) {
        assert className.indexOf('.') == -1;
        ClassDescriptor classDescriptor = classDescriptorMap.get(className);
        if (classDescriptor == null) {
            if (MODULE_INFO.getClassName().equals(className)) {
                // don't allow module info to be added to the map,
                // which could be used to check referenced classes
                return MODULE_INFO;
            }
            classDescriptor = new ClassDescriptor(className);
            classDescriptorMap.put(className, classDescriptor);
        }
        return classDescriptor;
    }
568967
ClassInfo getClassInfo(Class<?> effectiveType) {
        ClassInfo classInfo = classes.get(effectiveType);
        if (classInfo == null) {
            throw new IllegalStateException(
                    "Tried to serialise class that wasn't present in bean on first pass: " + effectiveType.getName());
        }
        return classInfo;
    }
305352
public static ObjectInfo getObjectInfo(Class c)
	{
		ObjectInfo info = cachedClassInfoMap.get(c);
		if (info == null)
		{
			synchronized (c)
			{

				info = new ObjectInfo(c);
				cachedClassInfoMap.put(c, info);
			}
		}
		return info;
	}
734613
public java.util.List<InstanceInformation> getInstanceInformationList() {
        if (instanceInformationList == null) {
            instanceInformationList = new com.amazonaws.internal.SdkInternalList<InstanceInformation>();
        }
        return instanceInformationList;
    }
1193730
private ClassDescriptorDef ensureClassDef(XClass original)
    {
        String             name     = original.getQualifiedName();
        ClassDescriptorDef classDef = _model.getClass(name);

        if (classDef == null)
        {
            classDef = new ClassDescriptorDef(original);
            _model.addClass(classDef);
        }
        return classDef;
    }