Tabnine Logo
DiscussionRecord
Code IndexAdd Tabnine to your IDE (free)

How to use
DiscussionRecord
in
org.kie.guvnor.services.metadata.model

Best Java code snippets using org.kie.guvnor.services.metadata.model.DiscussionRecord (Showing top 5 results out of 315)

origin: org.kie.guvnor/guvnor-core-services-backend

  @Override
  public int compare( final DiscussionRecord o1,
            final DiscussionRecord o2 ) {
    return o1.getTimestamp().compareTo( o2.getTimestamp() );
  }
} );
origin: org.kie.guvnor/guvnor-core-services-backend

public static Map<String, Object> toMap( final DiscussionAttributes attrs,
                     final String... attributes ) {
  return new HashMap<String, Object>() {{
    for ( final String attribute : attributes ) {
      checkNotEmpty( "attribute", attribute );
      if ( attribute.equals( "*" ) || attribute.equals( DISCUSS ) ) {
        for ( int i = 0; i < attrs.discussion().size(); i++ ) {
          final DiscussionRecord record = attrs.discussion().get( i );
          put( buildAttrName( TIMESTAMP, i ), record.getTimestamp() );
          put( buildAttrName( AUTHOR, i ), record.getAuthor() );
          put( buildAttrName( NOTE, i ), record.getNote() );
        }
      }
      if ( attribute.equals( "*" ) ) {
        break;
      }
    }
  }};
}
origin: org.kie.guvnor/guvnor-metadata-widget

  public void callback( final Long timestamp ) {
    showNewCommentButton();
    metadata.addDiscussion( new DiscussionRecord( timestamp, identity.getName(), text ) );
    makeDirty();
    updateCommentList();
  }
}, AppConfigService.class ).getTimestamp();
origin: org.kie.guvnor/guvnor-metadata-widget

private Widget appendComment( final DiscussionRecord r ) {
  final SmallLabel hrd = new SmallLabel( MetadataConstants.INSTANCE.smallCommentBy0On1Small( r.getAuthor(), new Date( r.getTimestamp() ) ) );
  hrd.addStyleName( "discussion-header" );
  commentList.add( hrd );
  final String[] parts = r.getNote().split( "\n" );
  if ( parts.length > 0 ) {
    final StringBuilder txtBuilder = new StringBuilder();
    for ( int i = 0; i < parts.length; i++ ) {
      txtBuilder.append( parts[ i ] );
      if ( i != parts.length - 1 ) {
        txtBuilder.append( "<br/>" );
      }
    }
    final HTML hth = new HTML( txtBuilder.toString() );
    hth.setStyleName( "form-field" );
    commentList.add( hth );
  } else {
    final Label lbl = new Label( r.getNote() );
    lbl.setStyleName( "form-field" );
    commentList.add( lbl );
  }
  commentList.add( new HTML( "<br/>" ) );
  return hrd;
}
origin: org.kie.guvnor/guvnor-core-services-backend

final String author = authors.get( i );
final String note = notes.get( i );
result.add( new DiscussionRecord( ts, author, note ) );
org.kie.guvnor.services.metadata.modelDiscussionRecord

Javadoc

This is a discussion record item.

Most used methods

  • <init>
  • getAuthor
  • getNote
  • getTimestamp

Popular in Java

  • Finding current android device location
  • getSharedPreferences (Context)
  • onRequestPermissionsResult (Fragment)
  • getSupportFragmentManager (FragmentActivity)
  • Table (com.google.common.collect)
    A collection that associates an ordered pair of keys, called a row key and a column key, with a sing
  • Graphics2D (java.awt)
    This Graphics2D class extends the Graphics class to provide more sophisticated control overgraphics
  • FileOutputStream (java.io)
    An output stream that writes bytes to a file. If the output file exists, it can be replaced or appen
  • System (java.lang)
    Provides access to system-related information and resources including standard input and output. Ena
  • Base64 (org.apache.commons.codec.binary)
    Provides Base64 encoding and decoding as defined by RFC 2045.This class implements section 6.8. Base
  • FileUtils (org.apache.commons.io)
    General file manipulation utilities. Facilities are provided in the following areas: * writing to a
  • Top plugins for Android Studio
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now