/** * Add all uniform entries of the given {@link Technique} to the given * {@link TechniqueModel} * * @param technique The {@link Technique} * @param techniqueModel The {@link TechniqueModel} */ private static void addUniforms(Technique technique, DefaultTechniqueModel techniqueModel) { Map<String, String> uniforms = Optionals.of(technique.getUniforms()); for (Entry<String, String> entry : uniforms.entrySet()) { String uniformName = entry.getKey(); String parameterName = entry.getValue(); techniqueModel.addUniform(uniformName, parameterName); } }
/** * Add all uniform entries of the given {@link Technique} to the given * {@link TechniqueModel} * * @param technique The {@link Technique} * @param techniqueModel The {@link TechniqueModel} */ private static void addUniforms(Technique technique, DefaultTechniqueModel techniqueModel) { Map<String, String> uniforms = Optionals.of(technique.getUniforms()); for (Entry<String, String> entry : uniforms.entrySet()) { String uniformName = entry.getKey(); String parameterName = entry.getValue(); techniqueModel.addUniform(uniformName, parameterName); } }
.ofNullable(technique.getUniforms()) .orElse(Collections.emptyMap()); for (String uniformName : uniforms.keySet())