Codota Logo
ExtendedAttributeView
Code IndexAdd Codota to your IDE (free)

How to use
ExtendedAttributeView
in
org.kie.commons.java.nio.base

Best Java code snippets using org.kie.commons.java.nio.base.ExtendedAttributeView (Showing top 4 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
DateTime d =
  • Codota Iconnew DateTime()
  • Codota IconDateTimeFormatter formatter;String text;formatter.parseDateTime(text)
  • Codota IconObject instant;new DateTime(instant)
  • Smart code suggestions by Codota
}
origin: org.kie.commons/kie-nio2-model

  private synchronized Properties buildProperties( boolean includesNonSerializable ) {
    final Properties properties = new Properties( content );

    for ( final Map.Entry<String, AttributeView> view : viewsNameIndex.entrySet() ) {
      if ( includesNonSerializable ||
          view.getValue() instanceof ExtendedAttributeView && ( (ExtendedAttributeView) view.getValue() ).isSerializable() ) {
        final ExtendedAttributeView extendedView = (ExtendedAttributeView) view.getValue();
        for ( final Map.Entry<String, Object> attr : extendedView.readAllAttributes().entrySet() ) {
          properties.put( attr.getKey(), attr.getValue() );
        }
      }
    }

    return properties;
  }
}
origin: org.kie.commons/kie-nio2-model

@Override
public <V extends AttributeView> void addAttrView( final V view ) {
  viewsNameIndex.put( view.name(), view );
  if ( view instanceof ExtendedAttributeView ) {
    final ExtendedAttributeView extendedView = (ExtendedAttributeView) view;
    for ( Class<? extends BasicFileAttributeView> type : extendedView.viewTypes() ) {
      viewsTypeIndex.put( type, view );
    }
  } else {
    viewsTypeIndex.put( view.getClass(), view );
  }
}
origin: org.kie.commons/kie-nio2-jgit

@Override
public Map<String, Object> readAttributes( final Path path,
                      final String attributes,
                      final LinkOption... options )
    throws UnsupportedOperationException, IllegalArgumentException, IOException, SecurityException {
  checkNotNull( "path", path );
  checkNotEmpty( "attributes", attributes );
  final String[] s = split( attributes );
  if ( s[ 0 ].length() == 0 ) {
    throw new IllegalArgumentException( attributes );
  }
  final ExtendedAttributeView view = getFileAttributeView( toPathImpl( path ), s[ 0 ], options );
  if ( view == null ) {
    throw new UnsupportedOperationException( "View '" + s[ 0 ] + "' not available" );
  }
  return view.readAttributes( s[ 1 ].split( "," ) );
}
origin: org.kie.commons/kie-nio2-jgit

@Override
public void setAttribute( final Path path,
             final String attribute,
             final Object value,
             final LinkOption... options )
    throws UnsupportedOperationException, IllegalArgumentException, ClassCastException, IOException, SecurityException {
  checkNotNull( "path", path );
  checkNotEmpty( "attributes", attribute );
  if ( attribute.equals( FileSystemState.FILE_SYSTEM_STATE_ATTR ) ) {
    try {
      state = FileSystemState.valueOf( value.toString() );
      FileSystemState.valueOf( value.toString() );
    } catch ( final Exception ex ) {
      state = FileSystemState.NORMAL;
    }
    hadCommitOnBatchState = false;
    return;
  }
  final String[] s = split( attribute );
  if ( s[ 0 ].length() == 0 ) {
    throw new IllegalArgumentException( attribute );
  }
  final ExtendedAttributeView view = getFileAttributeView( toPathImpl( path ), s[ 0 ], options );
  if ( view == null ) {
    throw new UnsupportedOperationException( "View '" + s[ 0 ] + "' not available" );
  }
  view.setAttribute( s[ 1 ], value );
}
org.kie.commons.java.nio.baseExtendedAttributeView

Most used methods

  • isSerializable
  • readAllAttributes
  • readAttributes
  • setAttribute
  • viewTypes

Popular in Java

  • Making http post requests using okhttp
  • getSystemService (Context)
  • onRequestPermissionsResult (Fragment)
  • runOnUiThread (Activity)
  • Point (java.awt)
    A point representing a location in (x, y) coordinate space, specified in integer precision.
  • System (java.lang)
    Provides access to system-related information and resources including standard input and output. Ena
  • MalformedURLException (java.net)
    Thrown to indicate that a malformed URL has occurred. Either no legal protocol could be found in a s
  • Format (java.text)
    The base class for all formats. This is an abstract base class which specifies the protocol for clas
  • HashSet (java.util)
    This class implements the Set interface, backed by a hash table (actually a HashMap instance). It m
  • Scheduler (org.quartz)
    This is the main interface of a Quartz Scheduler. A Scheduler maintains a registery of org.quartz
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now