当前位置: 首页 > news >正文

微信游戏网站源码怎么做seodg官网

微信游戏网站源码怎么做,seodg官网,表格可以做网站么,江山市建设局网站Spring条件评估器 1. ConditionEvaluator是干嘛的2. 先看其属性类ConditionContextImp context3. 看ConditionEvaluator 的内部方法4. AnnotationTypeMetadata 是干嘛的5. Condition 接口 1. ConditionEvaluator是干嘛的 内部的使用类,用来评估注解的 2. 先看其属性类Condition… Spring条件评估器 1. ConditionEvaluator是干嘛的2. 先看其属性类ConditionContextImp context3. 看ConditionEvaluator 的内部方法4. AnnotationTypeMetadata 是干嘛的5. Condition 接口 1. ConditionEvaluator是干嘛的 内部的使用类,用来评估注解的 2. 先看其属性类ConditionContextImp context private static class ConditionContextImpl implements ConditionContext {Nullableprivate final BeanDefinitionRegistry registry;Nullableprivate final ConfigurableListableBeanFactory beanFactory;private final Environment environment;private final ResourceLoader resourceLoader;Nullableprivate final ClassLoader classLoader;// 构造器, 实例化时构造这些参数public ConditionContextImpl(Nullable BeanDefinitionRegistry registry,Nullable Environment environment, Nullable ResourceLoader resourceLoader) {this.registry registry;this.beanFactory deduceBeanFactory(registry);this.environment (environment ! null ? environment : deduceEnvironment(registry));this.resourceLoader (resourceLoader ! null ? resourceLoader : deduceResourceLoader(registry));this.classLoader deduceClassLoader(resourceLoader, this.beanFactory);}Nullable// 根据子类类型推到出beanFactoryprivate ConfigurableListableBeanFactory deduceBeanFactory(Nullable BeanDefinitionRegistry source) {if (source instanceof ConfigurableListableBeanFactory) {return (ConfigurableListableBeanFactory) source;}if (source instanceof ConfigurableApplicationContext) {return (((ConfigurableApplicationContext) source).getBeanFactory());}return null;}// 获取到环境private Environment deduceEnvironment(Nullable BeanDefinitionRegistry source) {if (source instanceof EnvironmentCapable) {return ((EnvironmentCapable) source).getEnvironment();}return new StandardEnvironment();}// 推到出资源加载器private ResourceLoader deduceResourceLoader(Nullable BeanDefinitionRegistry source) {if (source instanceof ResourceLoader) {return (ResourceLoader) source;}// 不是ResouceLoader类型的话就初始化一个默认资源加载器return new DefaultResourceLoader();}Nullable// 不解释啦看不懂就别看了private ClassLoader deduceClassLoader(Nullable ResourceLoader resourceLoader,Nullable ConfigurableListableBeanFactory beanFactory) {if (resourceLoader ! null) {ClassLoader classLoader resourceLoader.getClassLoader();if (classLoader ! null) {return classLoader;}}if (beanFactory ! null) {return beanFactory.getBeanClassLoader();}return ClassUtils.getDefaultClassLoader();}Override// 获取beanDefinition注册器public BeanDefinitionRegistry getRegistry() {Assert.state(this.registry ! null, No BeanDefinitionRegistry available);return this.registry;}OverrideNullable// 返回beanFactorypublic ConfigurableListableBeanFactory getBeanFactory() {return this.beanFactory;}Overridepublic Environment getEnvironment() {return this.environment;}Overridepublic ResourceLoader getResourceLoader() {return this.resourceLoader;}OverrideNullablepublic ClassLoader getClassLoader() {return this.classLoader;} } // Context information for use by Condition implementations // 条件实现类使用的上下文信息类 public interface ConditionContext {// 获取BeanDefinition信息BeanDefinitionRegistry getRegistry();// 这不用说获取容器ConfigurableListableBeanFactory getBeanFactory();// 获取环境Environment getEnvironment();// 获取资源加载器ResourceLoader getResourceLoader();// 获取类加载器ClassLoader getClassLoader(); }3. 看ConditionEvaluator 的内部方法 // 构造器 public ConditionEvaluator(Nullable BeanDefinitionRegistry registry,Nullable Environment environment, Nullable ResourceLoader resourceLoader) {// 根据参数实例化条件上下文this.context new ConditionContextImpl(registry, environment, resourceLoader); }// 是否跳过 public boolean shouldSkip(AnnotatedTypeMetadata metadata) {return shouldSkip(metadata, null); }public boolean shouldSkip(Nullable AnnotatedTypeMetadata metadata, Nullable ConfigurationPhase phase) {if (metadata null || !metadata.isAnnotated(Conditional.class.getName())) {return false;}if (phase null) {if (metadata instanceof AnnotationMetadata ConfigurationClassUtils.isConfigurationCandidate((AnnotationMetadata) metadata)) {return shouldSkip(metadata, ConfigurationPhase.PARSE_CONFIGURATION);}return shouldSkip(metadata, ConfigurationPhase.REGISTER_BEAN);}ListCondition conditions new ArrayList();for (String[] conditionClasses : getConditionClasses(metadata)) {for (String conditionClass : conditionClasses) {Condition condition getCondition(conditionClass, this.context.getClassLoader());conditions.add(condition);}}AnnotationAwareOrderComparator.sort(conditions);for (Condition condition : conditions) {ConfigurationPhase requiredPhase null;if (condition instanceof ConfigurationCondition) {requiredPhase ((ConfigurationCondition) condition).getConfigurationPhase();}if ((requiredPhase null || requiredPhase phase) !condition.matches(this.context, metadata)) {return true;}}return false; }4. AnnotationTypeMetadata 是干嘛的 // 用于获取元素上的注解的元数据不用看了 MergedAnnotations getAnnotations();default boolean isAnnotated(String annotationName) {return getAnnotations().isPresent(annotationName); }default MapString, Object getAnnotationAttributes(String annotationName) {return getAnnotationAttributes(annotationName, false); }default MapString, Object getAnnotationAttributes(String annotationName,boolean classValuesAsString) {MergedAnnotationAnnotation annotation getAnnotations().get(annotationName,null, MergedAnnotationSelectors.firstDirectlyDeclared());if (!annotation.isPresent()) {return null;}return annotation.asAnnotationAttributes(Adapt.values(classValuesAsString, true)); }default MultiValueMapString, Object getAllAnnotationAttributes(String annotationName) {return getAllAnnotationAttributes(annotationName, false); }default MultiValueMapString, Object getAllAnnotationAttributes(String annotationName, boolean classValuesAsString) {Adapt[] adaptations Adapt.values(classValuesAsString, true);return getAnnotations().stream(annotationName).filter(MergedAnnotationPredicates.unique(MergedAnnotation::getMetaTypes)).map(MergedAnnotation::withNonMergedAttributes).collect(MergedAnnotationCollectors.toMultiValueMap(map -map.isEmpty() ? null : map, adaptations)); }5. Condition 接口 boolean matches(ConditionContext context, AnnotatedTypeMetadata metadata);
http://www.pierceye.com/news/377165/

相关文章:

  • 有没有做美食的网站深圳网站建站公司
  • 学校网站建设需求分析调研表网站右侧信息跟随左侧菜单栏变化
  • 家乡网站建设策划案邢台哪里建网站
  • 网站建设实习收获青岛网上房地产网站
  • 简述电子政务网站设计的技术企业邮箱是什么类型的账户
  • 深圳网站建设公司元嘉定网站开发
  • 佛山外贸网站建设平台上传网站安装教程
  • c2c网站建设实例德国网站建设
  • 建网站支持设备是什么意思佛山中小企业网站建设
  • 网站建设与管理读后感宁德住房和城乡建设部网站
  • 贸易网站建站建设部网站社保联网
  • 住房城乡建设厅网站准考证如何建小企业网站
  • 葫芦岛市城乡建设局网站做什么样的网站
  • 铜山区规划建设局网站大学生心理咨询网站建设论文
  • 泸州本地网站建设扬州做网站公司
  • 镇江网站建设工作室怎么购买国外的域名
  • 广西南宁电商网站建设找客户信息的软件
  • 信阳网站开发公司2022中国互联网公司市值排名
  • 巨鹿县住房与城乡建设厅网站wordpress内容付费插件
  • 网站设计建设维护wordpress 仿搜狗百科
  • 做网站写的代号好跟不好的区别中国500强企业官网
  • html个人网站wordpress 后台 字数统计
  • 网站开发包括哪些技术网站后台框架模版
  • 济南地产行业网站开发长春网络推广
  • 网站建设全程揭秘网站建设费能抵扣吗
  • 网站开发用什么语言最安全网站的ftp在哪里可以查到
  • 物理结构网站我国网站建设现状
  • 毕设如何做网站tk网站免费
  • 做logo的著名网站一起做网商网站怎么样
  • 楼盘销售管理网站开发资源网站界面设计形考