Package ptolemy.kernel.util

Examples of ptolemy.kernel.util.InternalErrorException


                try {
                    _debug("getAndReset: Gobbler '" + getName() + "' Ready: "
                            + _inputStreamReader.ready() + " Available: "
                            + _inputStream.available());
                } catch (Exception ex) {
                    throw new InternalErrorException(ex);
                }
            }

            try {
                // Read any remaining data.
                _read();
            } catch (Throwable throwable) {
                if (_debugging) {
                    _debug("WARNING: getAndReset(): _read() threw an "
                            + "exception, which we are ignoring.\n"
                            + throwable.getMessage());
                }
            }

            String results = _stringBuffer.toString();
            _stringBuffer = new StringBuffer();

            try {
                _inputStreamReader.close();
            } catch (Exception ex) {
                throw new InternalErrorException(null, ex, getName()
                        + " failed to close.");
            }

            return results;
        }
View Full Code Here


                    }

                    _stringBuffer.append(chars, 0, length);
                }
            } catch (Throwable throwable) {
                throw new InternalErrorException(_actor, throwable, getName()
                        + ": Failed while reading from " + _inputStream);
            }
        }
View Full Code Here

                        FileTypeDescriptor.MSVIDEO));
            } else if (_fileType == _MPEG) {
                processor.setContentDescriptor(new ContentDescriptor(
                        FileTypeDescriptor.MPEG));
            } else {
                throw new InternalErrorException("type = " + _fileType
                        + ", which is not one of " + _QUICKTIME
                        + "(QUICKTIME), " + _AVI + "(AVI) or " + _MPEG
                        + "(MPEG).");
            }
View Full Code Here

        try {
            newObject.output.setTypeAtLeast(ArrayType
                    .elementType(newObject.table));
        } catch (IllegalActionException e) {
            // Should have been caught before this.
            throw new InternalErrorException(e);
        }
        return newObject;
    }
View Full Code Here

        Sequence newObject = (Sequence) super.clone(workspace);
        try {
            newObject.output.setTypeAtLeast(ArrayType
                    .elementType(newObject.values));
        } catch (IllegalActionException e) {
            throw new InternalErrorException(e);
        }
        return newObject;
    }
View Full Code Here

        PoissonClock newObject = (PoissonClock) super.clone(workspace);
        try {
            newObject.output.setTypeAtLeast(ArrayType
                    .elementType(newObject.values));
        } catch (IllegalActionException e) {
            throw new InternalErrorException(e);
        }
        return newObject;
    }
View Full Code Here

     */
    protected static boolean _areConversionsPreferable(
            ArgumentConversion[] conversions1, Class[] arguments1,
            ArgumentConversion[] conversions2, Class[] arguments2) {
        if (conversions1.length != conversions2.length) {
            throw new InternalErrorException(
                    "Conversion arrays have to have the same length.");
        }

        for (int j = 0; j < conversions1.length; j++) {
            //  System.out.println("comparing " + conversions1[j]);
View Full Code Here

        try {
            newObject.output.setTypeAtLeast(ArrayType
                    .elementType(newObject.input));
        } catch (IllegalActionException e) {
            // Should have been caught before.
            throw new InternalErrorException(e);
        }
        return newObject;
    }
View Full Code Here

            try {
                step.update();
                _stateToken = _stateToken.add(step.getToken());
            } catch (IllegalActionException ex) {
                throw new InternalErrorException(this, ex,
                        "Should not be thrown because we have already "
                                + "verified that the tokens can be added");
            }
        }
View Full Code Here

        try {
            newObject.output.setTypeAtLeast(ArrayType
                    .elementType(newObject.alphabet));
        } catch (IllegalActionException e) {
            // Should have been caught before.
            throw new InternalErrorException(e);
        }
        return newObject;
    }
View Full Code Here

TOP

Related Classes of ptolemy.kernel.util.InternalErrorException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.