/** * Sets all values to false */ public void clear() { store.clear(); } }
@Override public TextGraphics clearModifiers() { activeModifiers.clear(); return this; }
@Override public Set clearModifiers() { style.clear(); return this; } @Override
@Override public TextGraphicsWriter clearModifiers() { style.clear(); return this; }
@Override public TextGraphics clearModifiers() { this.activeModifiers.clear(); return this; }
@Override public synchronized void resetColorAndSGR() { this.activeModifiers.clear(); this.activeForegroundColor = TextColor.ANSI.DEFAULT; this.activeBackgroundColor = TextColor.ANSI.DEFAULT; }
@Override public synchronized TextGraphics setModifiers(EnumSet<SGR> modifiers) { activeModifiers.clear(); activeModifiers.addAll(modifiers); return this; }
@Override public Set setModifiers(EnumSet<SGR> modifiers) { style.clear(); style.addAll(modifiers); return this; } @Override
@Override public TextGraphicsWriter setModifiers(EnumSet<SGR> modifiers) { style.clear(); style.addAll(modifiers); return this; }
public void setActions(Action[] assigned) { if (assigned != null && assigned.length > 0) { // setActions should cover the previous actions, // so we call clear here. actions.clear(); actions.addAll(Arrays.asList(assigned)); } }
/** * Sets the auto-close trigger to use on this terminal. This will reset any previous triggers. If called with * {@code null}, all triggers are cleared. * @param autoCloseTrigger Auto-close trigger to use on this terminal, or {@code null} to clear all existing triggers * @return Itself */ public SwingTerminalFrame setAutoCloseTrigger(TerminalEmulatorAutoCloseTrigger autoCloseTrigger) { this.autoCloseTriggers.clear(); if(autoCloseTrigger != null) { this.autoCloseTriggers.add(autoCloseTrigger); } return this; }
/** * Sets the auto-close trigger to use on created SwingTerminalFrames created by this factory. This will reset any * previous triggers. If called with {@code null}, all triggers are cleared. * @param autoCloseTrigger Auto-close trigger to use on created SwingTerminalFrames created by this factory, or {@code null} to clear all existing triggers * @return Reference to itself, so multiple .set-calls can be chained */ public DefaultTerminalFactory setTerminalEmulatorFrameAutoCloseTrigger(TerminalEmulatorAutoCloseTrigger autoCloseTrigger) { this.autoCloseTriggers.clear(); if(autoCloseTrigger != null) { this.autoCloseTriggers.add(autoCloseTrigger); } return this; }
FontConfiguration add(FontStyle style) { final EnumSet<FontStyle> r = styles.clone(); if (style == FontStyle.PLAIN) { r.clear(); } r.add(style); return new FontConfiguration(r, motherFont, motherColor, currentFont, currentColor, extendedColor, fontPosition, svgAttributes, hyperlink, hyperlinkColor, useUnderlineForHyperlink, tabSize); }
/** * Sets the shaders that this technique definition will use. * * @param vertexShader The name of the vertex shader * @param fragmentShader The name of the fragment shader * @param vertLanguage The vertex shader language * @param fragLanguage The fragment shader language */ public void setShaderFile(String vertexShader, String fragmentShader, String vertLanguage, String fragLanguage) { this.shaderLanguages.put(Shader.ShaderType.Vertex, vertLanguage); this.shaderNames.put(Shader.ShaderType.Vertex, vertexShader); this.shaderLanguages.put(Shader.ShaderType.Fragment, fragLanguage); this.shaderNames.put(Shader.ShaderType.Fragment, fragmentShader); requiredCaps.clear(); Caps vertCap = Caps.valueOf(vertLanguage); requiredCaps.add(vertCap); Caps fragCap = Caps.valueOf(fragLanguage); requiredCaps.add(fragCap); weight = Math.max(vertCap.ordinal(), fragCap.ordinal()); }
private void updateAvailableFeatures() { availableFeatures.clear(); // Check which features are used in the shaders and update the available features mask accordingly for (ShaderProgramFeature feature : ShaderProgramFeature.values()) { // TODO: Have our own shader language and parse this stuff out properly if (shaderProgramBase.getFragmentProgram().contains(feature.toString())) { logger.debug("Fragment shader feature '" + feature.toString() + "' is available..."); availableFeatures.add(feature); } else if (shaderProgramBase.getVertexProgram().contains(feature.toString())) { logger.debug("Vertex shader feature '" + feature.toString() + "' is available..."); availableFeatures.add(feature); } } }
@Override public void setConfig(byte lruAlgorithm, byte lruAction, int lruLimit, int concurrencyLevel, int initialCapacity, float loadFactor, boolean statisticsEnabled, boolean isBucket, EnumSet<DiskRegionFlag> flags, String partitionName, int startingBucketId, String compressorClassName, boolean offHeap) { this.lruAlgorithm = lruAlgorithm; this.lruAction = lruAction; this.lruLimit = lruLimit; this.concurrencyLevel = concurrencyLevel; this.initialCapacity = initialCapacity; this.loadFactor = loadFactor; this.statisticsEnabled = statisticsEnabled; this.isBucket = isBucket; if (flags != null && flags != this.flags) { this.flags.clear(); this.flags.addAll(flags); } this.partitionName = partitionName; this.startingBucketId = startingBucketId; this.compressorClassName = compressorClassName; this.offHeap = offHeap; if (!ds.isOffline()) { createCompressorFromClassName(); } }
/** * Sets the shaders that this technique definition will use. * * @param shaderNames EnumMap containing all shader names for this stage * @param shaderLanguages EnumMap containing all shader languages for this stage */ public void setShaderFile(EnumMap<Shader.ShaderType, String> shaderNames, EnumMap<Shader.ShaderType, String> shaderLanguages) { requiredCaps.clear(); weight = 0; for (Shader.ShaderType shaderType : shaderNames.keySet()) { String language = shaderLanguages.get(shaderType); String shaderFile = shaderNames.get(shaderType); this.shaderLanguages.put(shaderType, language); this.shaderNames.put(shaderType, shaderFile); Caps cap = Caps.valueOf(language); requiredCaps.add(cap); weight = Math.max(weight, cap.ordinal()); if (shaderType.equals(Shader.ShaderType.Geometry)) { requiredCaps.add(Caps.GeometryShader); } else if (shaderType.equals(Shader.ShaderType.TessellationControl)) { requiredCaps.add(Caps.TesselationShader); } } }
/** * If true, the last modified time, last access time, * owner, group and permission information of the source * file will be preserved as far as target {@link FileSystem} * implementation allows. */ protected void setPreserve(boolean preserve) { if (preserve) { preserve(FileAttribute.TIMESTAMPS); preserve(FileAttribute.OWNERSHIP); preserve(FileAttribute.PERMISSION); } else { preserveStatus.clear(); } }
@Override public void setDependedToType(DependencyType dependencyType) { dependendToTypes.clear(); dependendToTypes.add(dependencyType); }
@Override public IItemBuilder features( AEFeature... features ) { this.features.clear(); this.addFeatures( features ); return this; }