Package org.auraframework.impl.expression

Examples of org.auraframework.impl.expression.PropertyReferenceImpl$Serializer


   *
   * @param conf Configuration to use
   * @return A new, configured, Serializer
   */
  public Serializer createSerializer(Configuration conf) {
    Serializer serializer = ReflectionUtils.newInstance(serializerClass, conf);
    SerDes.initSerializer(serializer, conf, columnInfo, serializerParams);
    return serializer;
  }
View Full Code Here


    OutputInfo oti = outputConf.readOutputTableInfo();

    HiveUtils.setRCileNumColumns(conf, oti.getColumnInfo().size());
    HadoopUtils.setOutputKeyWritableClass(conf, NullWritable.class);

    Serializer serializer = oti.createSerializer(conf);
    HadoopUtils.setOutputValueWritableClass(conf,
        serializer.getSerializedClass());

    org.apache.hadoop.mapred.OutputFormat baseOutputFormat =
        ReflectionUtils.newInstance(oti.getOutputFormatClass(), conf);
    // CHECKSTYLE: stop LineLength
    org.apache.hadoop.mapred.RecordWriter<WritableComparable, Writable> baseWriter =
View Full Code Here

    HiveOutputFormat<?, ?> hiveOutputFormat = null;
    Class<? extends Writable> outputClass = null;
    boolean isCompressed = conf.getCompressed();
    TableDesc tableInfo = conf.getTableInfo();
    try {
      Serializer serializer = (Serializer) tableInfo.getDeserializerClass().newInstance();
      serializer.initialize(null, tableInfo.getProperties());
      outputClass = serializer.getSerializedClass();
      hiveOutputFormat = conf.getTableInfo().getOutputFileFormatClass().newInstance();
    } catch (SerDeException e) {
      throw new HiveException(e);
    } catch (InstantiationException e) {
      throw new HiveException(e);
View Full Code Here

    public ComponentConfig provide() throws QuickFixException {
        BaseComponent<?, ?> component = Aura.getContextService().getCurrentContext().getCurrentComponent();
        ComponentConfig cc = new ComponentConfig();
        Map<String, Object> m = Maps.newHashMapWithExpectedSize(1);
        // so now we're relying on the fact that the data provider's model has items on it, thats fantastic.
        m.put("items", component.getAttributes().getValue(new PropertyReferenceImpl("dataProvider.0.m.items", null)));
        cc.setAttributes(m);
        return cc;
    }
View Full Code Here

        for (DefDescriptor<AttributeDef> desc : attrs.keySet()) {
            Object val = lookup.get(desc);
            if (val != null) {
                if (val instanceof Attribute) {
                    Attribute attribute = (Attribute) val;
                    setExpression(attribute.getDescriptor(), new PropertyReferenceImpl("v." + attribute.getName(),
                            SUPER_PASSTHROUGH));
                } else if (val instanceof AttributeDefRef) {
                    set((AttributeDefRef) val);
                }
            }
View Full Code Here

        }
    }

    @Override
    public Object getValue(String name) throws QuickFixException {
        PropertyReference expr = new PropertyReferenceImpl(name,
                AuraUtil.getExternalLocation("direct attributeset access"));
        if (expr.size() != 1) {
            throw new InvalidDefinitionException("No dots allowed", expr.getLocation());
        }
        return getValue(expr);
    }
View Full Code Here

                 
                  if (propRefs == null) {
                      propRefs = Sets.newHashSet();
                  }
                 
          propRefs.add(new PropertyReferenceImpl(labelRef, location));
                }
             
                result = raw;
            }
           
View Full Code Here

    @AuraEnabled
    public static String getLabel(@Key("section") String section, @Key("name") String name) throws QuickFixException {
        GlobalValueProvider labelProvider = Aura.getContextService().getCurrentContext().getGlobalProviders()
                .get(LABEL);
        PropertyReference labelRef = new PropertyReferenceImpl(section + "." + name, null);
        return (String) labelProvider.getValue(labelRef);
    }
View Full Code Here

        bvp.validate(BrowserProperty.isIPad);
        bvp.validate(BrowserProperty.isIPhone);
        bvp.validate(BrowserProperty.isIOS);
        bvp.validate(BrowserProperty.isWindowsPhone);

        PropertyReference property = new PropertyReferenceImpl("hah", null);
        try {
            bvp.validate(property);
            fail("Expected InvalidExpressionException for " + property);
        } catch (InvalidExpressionException e) {
            assertEquals("No property on $Browser for key: " + property,
View Full Code Here

    }

    public void testGetValueUndefinedProperty() throws Exception {
        BrowserValueProvider bvp = new BrowserValueProvider();
        assertEquals(null,
                bvp.getValue(new PropertyReferenceImpl("isBlackberry", null))); // undefined property
    }
View Full Code Here

TOP

Related Classes of org.auraframework.impl.expression.PropertyReferenceImpl$Serializer

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.