c# - How to name a Class whose only purpose is to return a Boolean -


i have class sole responsibility tell me if remote command has returned yes or no , i'm not sure how name it.

more specifically, application front end collection of linux commands. communicate linux via ssh. each business operation (ex. getitem, createitem, getitemcount, etc) maps command class. each command class derives base ssh command class handles communication details.

my latest command check if remote file of type (let's call doodle type). achieve remote file run through remote program , if program returns 1 or more lines on console file doodle.

now i'm struggling how name class.

if method , not class call isdoodle. because class involves getting information remote location , derives command base class, i'm tempted use getisdoodlecommand.

any thoughts?

update

while understand suggestion of using commandresult don't think fits in existing pattern use. or maybe don't understand! either way, think original question benefit few more details:

  • the base class abstract, , has abstract execute method
  • the derived command classes responsible implementing execute
  • the base class generic (public class commandbase<t>)
  • the return type of execute t

so typical usage of derived class be:

var namemecommand = new namemecommand(); bool isdoodle = namemecommand.execute();  var getitemcommand = new getitemcommand(); item myitem = getitemcommand.execute(); 

i isdoodlecommandresult .


Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -