Skip to content

Commit

Permalink
Change {function(new:ObjectIO)} to {IOType}, see phetsims/tandem#211
Browse files Browse the repository at this point in the history
  • Loading branch information
samreid committed Sep 29, 2020
1 parent 9c65951 commit 833f08b
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 6 deletions.
5 changes: 2 additions & 3 deletions js/Action.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,8 @@ class Action extends PhetioObject {
// phet-io - see PhetioObject.js for doc
tandem: Tandem.OPTIONAL,

// {function(new:function(new:ObjectIO),parameterTypes:function(new:ObjectIO))[]} - The non parameterized TypeIO, because
// passing in parameters. Override this to create a subtype of ActionIO as the phetioType instead of a
// parameterized ActionIO Type.
// {function(IOType[]):IOType} - The non parameterized TypeIO. Override this to create a subtype of ActionIO as
// the phetioType instead of a parameterized ActionIO Type.
phetioOuterType: Action.ActionIO,
phetioState: false,
phetioPlayback: PhetioObject.DEFAULT_OPTIONS.phetioPlayback,
Expand Down
2 changes: 1 addition & 1 deletion js/DerivedProperty.js
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ const orFunction = ( value, property ) => {
return value || property.value;
};

// {Object.<parameterTypeName:string, function(new:ObjectIO)>} - Cache each parameterized DerivedPropertyIO so that
// {Object.<parameterTypeName:string, IOType>} - Cache each parameterized DerivedPropertyIO so that
// it is only created once.
const cache = {};

Expand Down
2 changes: 1 addition & 1 deletion js/ObservableArray.js
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,7 @@ class ObservableArray extends PhetioObject {
}
}

// {Object.<parameterTypeName:string, function(new:ObjectIO)>} - Cache each parameterized ObservableArray.ObservableArrayIO so that it
// {Object.<parameterTypeName:string, IOType>} - Cache each parameterized ObservableArray.ObservableArrayIO so that it
// is only created once.
const cache = {};

Expand Down
2 changes: 1 addition & 1 deletion js/PropertyIO.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import VoidIO from '../../tandem/js/types/VoidIO.js';
import axon from './axon.js';
import Property from './Property.js';

// {Map.<cacheKey:function(new:ObjectIO), function(new:ObjectIO)>} - Cache each parameterized PropertyIO based on
// {Map.<IOType, IOType>} - Cache each parameterized PropertyIO based on
// the parameter type, so that it is only created once
const cache = new Map();

Expand Down

0 comments on commit 833f08b

Please sign in to comment.